[squeak-dev] Source file index encoding rant

Igor Stasenko siguctua at gmail.com
Sat Dec 12 12:57:30 UTC 2009


Hello,

encoding a file index in the highest bits of source pointer preventing
from having source file index > 32M :(

I mean, if we would encode pointer as:

(filePosition << 1) + (fileIndex -1) "file index 1 or 2 "
then there is no limit in .changes and .source files sizes, because
then its easy to represent such value as a byte array,
and it will mean only longer trailer bytes in compiled method, if
source file index above 32M.

But the way, how its encoded currently:

index * 16r1000000 + position

means that we're unable to have file position more than 32M :(

See implementation of #sourcePointerFromFileIndex:andPosition:

This should be fixed!

-- 
Best regards,
Igor Stasenko AKA sig.



More information about the Squeak-dev mailing list