From: William Djaja Tjokroaminata Date: 2002-09-06T01:48:15+09:00 Subject: Re: Best GC for Ruby? Well, currently int is usually 32 bits and most pointers are 32 bits and we already sacrifice one bit. Therefore, when 64-pointers are standard, I guess at least in theory we can do the same thing to double. Except, of course, we can judge how "nasty" it is, as compared to the performance that will be gained. (Isn't it the structure of 'double' and 'float' has been standardized by IEEE a long time ago?) Regards, Bill ============================================================================ Paul Brannan wrote: > On Fri, Sep 06, 2002 at 01:08:04AM +0900, William Djaja Tjokroaminata wrote: >> Which brings us to the second topic: the object model. In Ruby, in the >> spirit of Smalltalk, everything is an object. In Java, certain data types >> (such as int, float, and double) are "native" while the rest are >> objects. In Ruby, I guess for optimization purpose, you have put the >> 'int' as an immediate object, at the cost of 1 bit. Therefore, in the >> future, when 64-bit pointer is very common, will you also put the 'double' >> as an immediate object, and therefore probably approaching the Java model? > 'double' is already 64 bits, and so won't fit, unless we do some nasty > manipulation of the mantissa. We'd instead have to switch to using > floats, which are 32 bits. > Paul