On 09-Jan-2003, Ross Paterson <[EMAIL PROTECTED]> wrote:
> Two additions I think are required:
> 
> 1) The spec should state that mallocBytes and allocaBytes return a block
>    of memory sufficiently aligned for any of the primitive types supported
>    by the architecture.

I disagree.  These routines should only be required to align the memory
sufficiently for any of the primitive types which could fit in the amount
of space allocated.  For example, double precision floats might occupy
8 bytes, and require 8-byte alignment, but four-bytes allocations should
not be required to be 8-byte aligned.

(This is something the C standard got wrong, IMHO.)

-- 
Fergus Henderson <[EMAIL PROTECTED]>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
_______________________________________________
FFI mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/ffi

Reply via email to