[squeak-dev] The Inbox: Kernel-cmm.1198.mcz

Chris Muller asqueaker at gmail.com
Sat Nov 24 20:08:07 UTC 2018


> > Chris Muller uploaded a new version of Kernel to project The Inbox:
> > http://source.squeak.org/inbox/Kernel-cmm.1198.mcz
> >
> > ==================== Summary ====================
> >
> > Name: Kernel-cmm.1198
> > Author: cmm
> > Time: 23 November 2018, 11:12:47.414703 pm
> > UUID: fe228ca8-2ec7-4432-b3d9-76da98be4475
> > Ancestors: Kernel-eem.1197
> >
> > - Suggestion that #basicClass should be inlined while #class should be a message send, so that Proxy's can be supported.
>
> It won't work while the special bytecode for #class is compiled. And even
> after that, you have to recompile all senders of #class to make it use
> the primitive and the new method instead of optimizing it away.

Right.  Assuming we can achieve consensus with Eliot, and the next
Squeak will have a new VM, then that would be called from an MC post
script.

But what do you mean make all senders of #class use the primitive?
Just as you suggested the use of #ensureNonProxiedReceiver from the
other thread, the intention here is that #basicClass would better
document those performance-critical places, but leaving the majority
(of non-critical ones) sending #class, so it can be overridable.

Do you think the system would be noticably slower if all the sends to
#class became a message send?  I'm skeptical that it would, but I have
no idea.  I am surprised to see we have so many senders of #class in
trunk, but I have a feeling most rarely ever called.

Removing those byteCodes from my CompiledMethods is above my knowledge
level, but if you could help me come up with a script, I'd be
interested in testing and playing around to learn more.

> > - If so, then #xxxClass can be banished.
> > - With #xxxClass banished, the Squeak code that called it can be written normally, simply as "class".
>
> That won't work either for the same reason. And we do not want to remove
> the bytecode, do we?

Not remove it, redirect it to #basicClass.

This is a reasonable and familiar pattern, right?  It provides users
full control and WYSIWIG between source and bytecodes due to a crystal
clear selector name.  No magic.

 - Chris

 - Chris


More information about the Squeak-dev mailing list