Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Alignment of data
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2010-01-27 (16:38)
From: Pascal Cuoq <Pascal.Cuoq@c...>
Subject: Alignment of data

Goswin von Brederlow <> wrote:

> You need to write a new function
> CAMLextern value caml_alloc_double_array (mlsize_t),
> or similar that ensures alignment on 8 byte for double even for 32bit
> systems.
> You should also check the CAMLextern value caml_copy_double (double);
> that it does the same.

If you decide to go this route, which this message
neither endorses not condemns, you also need to

A1/ allocate the doubles directly in the major heap, and
A2/ deactivate compactions


B/ modify the garbage-collector.