[squeak-dev] Lightweight Classes

Igor Stasenko siguctua at gmail.com
Thu Nov 20 02:55:41 UTC 2008


2008/11/20 Michael van der Gulik <mikevdg at gmail.com>:
>
>
> On Thu, Nov 20, 2008 at 12:04 PM, Eliot Miranda <eliot.miranda at gmail.com>
> wrote:
>>
>>
>> On Wed, Nov 19, 2008 at 2:45 PM, Michael van der Gulik <mikevdg at gmail.com>
>> wrote:
>>>
>>>
>>> On Thu, Nov 20, 2008 at 7:29 AM, Eliot Miranda <eliot.miranda at gmail.com>
>>> wrote:
>>>>
>>>> To fix this change
>>>> bytecodePrimClass
>>>> | rcvr |
>>>> rcvr := self internalStackTop.
>>>> self internalPop: 1 thenPush: (self fetchClassOf: rcvr).
>>>> self fetchNextBytecode.
>>>> to
>>>> bytecodePrimClass
>>>> messageSelector := self specialSelector: 23.
>>>> argumentCount := 0.
>>>> self normalSend.
>>>
>>> Eliot: have you submitted this to the VM guys (via bugs.squeak.org I
>>> guess)?
>>>
>>> If not, let me know and I'll fill in a bug report.
>>
>> Arguably it's not a bug, but an obsolete optimization.  Feel free to
>> submit the bug, but I'll probably change it in Cog anyway.  I'll talk it
>> over with Andreas on Friday.
>
> now http://bugs.squeak.org/view.php?id=7229
>
don't forget that when you replaced #class with #primitiveClass in
special selectors array, now all you need is to recompile all methods
which had #class sends , otherwise this trick will work only inside a
new methods only :)

> Gulik.
>
> --
> http://people.squeakfoundation.org/person/mikevdg
> http://gulik.pbwiki.com/
>
>
>
>



-- 
Best regards,
Igor Stasenko AKA sig.



More information about the Squeak-dev mailing list