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
[Caml-list] boxing of floats in records/classes
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Xavier Leroy <xavier.leroy@i...>
Subject: Re: [Caml-list] boxing of floats in records/classes
> Would it then be false to assume that if you have many floats in a record,
> grouping them into a subrecord would reduce the boxing overhead ?

This is true, even if you have as little as two float fields.
However, there would be some overhead when accessing one of these
fields, in the case where you need the field value to remain boxed
(i.e. to pass it to a Caml function).  Also, this appraoch sure would
not simplify the compiler :-)

- Xavier Leroy
To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: