Browse thread
float precision on AMD64
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Ville-Pertti Keinonen <will@e...> |
| Subject: | Re: [Caml-list] float precision on AMD64 |
sejourne_kevin wrote: > The programs who works with floats in 32 bits shall also work with > floats in 64 bits without one bit from the mantissa, no? Extra precision does not automatically translate to things just working "better", as people have noticed based on the unfortunate x87 design choices. Besides, lots of (most?) programs want full 64-bit floats. Certainly OCaml programs would expect them. > So, what are we waiting for unbox the floats? > Historical reason(C code wrote that use the box representation of the > floats) ? OCaml is already capable of unboxing 64-bit floats when stored in arrays or records containing only floats. By using those, you should get reasonable efficiency. While tagged floats might be a usable solution for some situations, I'm sure I wouldn't be the only person unhappy with the situation if they were made the default. In OCaml they'd also be incompatible with polymorphic compare; unlike other values with a tagged representation, they can't be compared as if they were integers.