[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mirage/kFreeBSD on GitHub



On 6 Aug 2012, at 16:58, PALI Gabor Janos <pgj@xxxxxxx> wrote:

> On Mon, Aug 06, 2012 at 04:42:48PM +0100, Anil Madhavapeddy wrote:
>> That may be a patch worth upstreaming, as there are other
>> supported platforms with soft-floats that would benefit from not
>> requiring FP as part of the standard library.
> 
> Sure, my modifications in the run-time library are already separated by #ifdef
> _KERNEL lines.  Regarding the stdlib, it is now a standalone OCaml package, 
> but
> it may be possible to merge it with the upstream sources later on.
> 
> However, I think that floating-point code is so popular in OCaml libraries
> because such values are guaranteed to be 64-bit on most platforms, and
> therefore let the developers play with larger numbers.  Note that we also
> maintain the assumption that the target platform is 64-bit, so these changes
> will mostly work with processors of that kind.  (Like my fix for the garbage
> collector, where every number is shifted by one billion -- perhaps I could
> have done it in a more elegant way, though.)

The native int is either 31- or 64-bit, but you could always use the Int64
module (which is a boxed, precisely 64-bit value irrespective of the target
architecture).  Unfortunately, the GC module has exported a float-based 
interface
for over a decade, so I imagine there'll be some resistance to changing it
without a really good reason.  Of course, our performance results will be a
good reason, I hope! :-)

-anil


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.