[Vm-dev] [commit][3152] Make sure to compile the SmallFloat64 primitives.

Eliot Miranda eliot.miranda at gmail.com
Fri Nov 28 01:49:51 UTC 2014

On Thu, Nov 27, 2014 at 5:17 PM, Andres Valloud <
avalloud at smalltalk.comcastbiz.net> wrote:

> I'd rather this didn't happen... now we will always have to remember that
> "float32" is really what everybody else calls "float", "float64" is really
> what everybody else calls "double", and "float80" is... who knows... maybe
> the x87 extended double...

I don't see this.  Squeak has had Float for a long time, and for those that
know C that's confusing since float there-in means 32-bit single-precision,
whereas in Squeak Float means 64-bits (double precision).  But as Bert
said, Float64 is what JavaScript calls double-precision, and BoxedFloat64
and SmallFloat64 are good descriptive terms.  They don't match VisualWorks,
but that's not been a problem in practice.

It is a "double", what's the problem with calling it a "double"?

Double's not got a good dual for single-precision.  SIngle is a poor name.
 that's what really made me lean to Bert's suggestion, that if wanted we
can add Float32, or even Float80, and Float32 is a much better name than
Single.  SinglePrecisionFloat is a mouthful.  What we have now means that
Squeak and Pharo (and perhaps Newspeak) code will continue to use Float,
since the concrete names don't need to be used, or even recognized, except
in specialized contexts (e.g. intra-dialect copying?), since Floats print
themselves literally.

Also, using C's names isn't a good rationale.  It may work for VM
implementors but has nothing of value for Smalltalk programmers.

On 11/26/14 14:42 , Eliot Miranda wrote:
>> No.  Bert suggested (IIRC) ImmediateFloat64 and BoxedFloat64 and I went
>> with SmallFloat64 and BoxedFloat64 for two reasons.  SmallFloat64
>> because I like the symmetry with SmallInteger, and because this name
>> scheme gracefully admits SmallFloat32, BoxedFloat32 and BoxedFloat80 if
>> ever there was the energy to add them.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20141127/d12f3f5b/attachment-0001.htm

More information about the Vm-dev mailing list