Bytecode question: the send instruction
Alexandre Bergel
bergel at iam.unibe.ch
Wed May 14 09:41:47 UTC 2003
Thanks for your long email.
> 1356 flush calls which only resulted in 856 cache entries being
> invalidated. This seems much better than flushing all 512 entries in
> the method cache on each incremental GC event. I also noted that in
> lookupInMethodCacheSelclass, the number of calls was about 50
> million,and cache hits: 20M on probe1, 16M on probe2, 11M on probe3 and
> 1.8M not found
This mean 3.6% of the method call are not cached? This sounds strange as this value is very low, I was expected something about 10%
> Also note that Scott A Crosby <crosby at qwes.math.cmu.edu> on Sun Dec 9,
> 2001wrote
> "New method cache, 30% faster macrobenchmarks and ineffeciencies."
>
> One should look in the archives for the details
Yep, I found it http://lists.squeakfoundation.org/pipermail/squeak-dev/2001-December/031810.html
Thanks for pointing me out this mail, the thread is really interesting. I learnt a lot about hash mechanism.
Cheers,
Alexandre
> Mmm now if I recall I'm sure Tim, Ian and I looked (yes in sept 2002)
> into just the caching changes and couldn't generate
> the numbers that justified the complexity (or the extra memory) for the
> change required.
>
> On Tuesday, May 13, 2003, at 07:01 AM, Alexandre Bergel wrote:
>
> >Hello!
> >
> >By reading the green book, I have some question related the send
> >bytecode (page 210):
> > - "Approximately every third instruction is a message send and sends
> >requiring dictionary lookups occur every 6.667 bytecodes. Of the sends
> >needing dictionary searches, 36.64% invoked primitives, and the rest
> >resulted in the execution of a Smalltalk method which, along with
> >process switches, accounted for a context switch every 6.50 > bytecodes."
> > - "... 78.92% are arithmetic and logical operations..."
> >
> >This article was made in 1982, I would like to know it these
> >proportion are still equivalent nowadays.
> >
> >A bit related to this, what is the effect of the method cache? In the
> >average, what is the % of the method found in the cache?
> >
> >I heard once that only 1/10th of the message send are really
> >polymorphic, and the rest is mono-morphic.
> >
> >Cheers,
> >Alexandre
> >
> >--
> >_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
> >Alexandre Bergel http://www.iam.unibe.ch/~bergel
> >^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
> >
> >
> >
> --
> ========================================================================
> ===
> John M. McIntosh <johnmci at smalltalkconsulting.com> 1-800-477-2659
> Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com
> ========================================================================
> ===
>
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel http://www.iam.unibe.ch/~bergel
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
More information about the Squeak-dev
mailing list
|