Everything is a Register!
J J
azreal1977 at hotmail.com
Mon May 7 18:46:19 UTC 2007
>From: Mathieu Suen <mathk.sue at gmail.com>
>Reply-To: The general-purpose Squeak developers
>list<squeak-dev at lists.squeakfoundation.org>
>To: The general-purpose Squeak developers
>list<squeak-dev at lists.squeakfoundation.org>
>Subject: Re: Everything is a Register!
>Date: Mon, 7 May 2007 15:08:49 +0200
>
>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
But this is talking to the Smalltalk VM, which is a stack machine. He is
trying to write directly to the host CPU, which is more register oriented.
_________________________________________________________________
Download Messenger. Join the im Initiative. Help make a difference today.
http://im.live.com/messenger/im/home/?source=TAGHM_APR07
More information about the Squeak-dev
mailing list
|