Everything is a Register!

Mathieu Suen mathk.sue at gmail.com
Mon May 7 13:08:49 UTC 2007


On May 7, 2007, at 2:50 PM, sig wrote:

> lol.. i missed the collapsed quoted text and thought that Mathieu
> complaining about smalltalk syntax given in example, not intermediate
> form. :)))

Not complaining juste asking :)

>
> No, Mathieu, you'll write an asm routine as regular smalltalk method,
> just using special set of selectors :)
> Everything else is not your problem.
>


You can take a look at the NewCompiler you can write somthings like:

	| iRMethod aCompiledMethod |
	iRMethod := IRBuilder new
		numRargs: 1;
		addTemps: #(self);		"receiver and args declarations"		
		pushLiteral: $e; 	
		returnTop;
		ir.

	aCompiledMethod := iRMethod compiledMethod.
	aCompiledMethod valueWithReceiver: nil arguments: #()

	Mth



More information about the Squeak-dev mailing list