Browse thread
Bigarrays and blocking_section..
-
Romain Beauxis
- Dmitry Bely
-
Alain Frisch
- Goswin von Brederlow
[
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: | 2010-05-26 (06:47) |
From: | Goswin von Brederlow <goswin-v-b@w...> |
Subject: | Re: [Caml-list] Bigarrays and blocking_section.. |
Alain Frisch <alain@frisch.fr> writes: > On 5/25/2010 6:25 PM, Romain Beauxis wrote: >> My understanding is that after the line "frame_of_value(_rgb,&rgb);", the C >> object rgb only contains ints and a pointer to a block of memory allocated by >> malloc. > > Did you allocated the C array yourself with malloc? (And then used > alloc_bigarray to wrap it as an OCaml bigarray.) Otherwise, if you > created the bigarray from OCaml code, you need to keep the bigarray > live > with some GC root, or the memory for the array can be released. > > > Alain He did declare it as local varaible with the proper makro I believe. MfG Goswin