Something I noticed when looking at ByteArray>>hex, anyone know the  
reason why there's GC going on in do: with closure images, but not  
using the old bytecodes?
Even with no closed-over variables in the block, it seems it creates  
extra fodder for the Garbage collector...

Is it something the stack VM / Improved Garbage Collector will change?

Cheers,
Henry

Simple test:
intArray := (1 to: 10000000) asArray.
TimeProfileBrowser onBlock: [intArray  do: [:ix | ix yourself]]
(It's not due to sampling overhead, Time millisecondsToRun: return  
similiar runtimes)

Without closures (I used 250):
-941 tallies, 965 msec.
**GCs**
incr 4 totalling 0ms

With closures (I used 414):
-1938 tallies, 1938 msec.
**GCs**
inc 2510 totalling 614ms


_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to