Browse thread
[Caml-list] OCaml signal handlers (Sys.signal) and C code
-
Stefano Zacchiroli
-
Xavier Leroy
- Stefano Zacchiroli
- Stefano Zacchiroli
-
Xavier Leroy
[
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: | -- (:) |
| From: | Stefano Zacchiroli <zack@b...> |
| Subject: | Re: [Caml-list] OCaml signal handlers (Sys.signal) and C code |
On Wed, Apr 16, 2003 at 09:16:07PM +0200, Xavier Leroy wrote:
> honored immediately. However, the C code executed inside the blocking
> section *must not* heap-allocate nor access the Caml heap in any way.
> In practice, this means that all conversions between Caml and C data
> structures must be done outside the blocking section:
Your "in any way" include also read only access (e.g. "Field" invocation
on a caml value allocated outside the blocking section), right?
If this is the case I'm a bit concerned about performances. I have a
piece of C code, invoked by OCaml, that access caml values inside a
loop. To convert this code so that it can be interrupted by ocaml
callbacks I have to enter blocking before each access and exit
afterwards. Is this entering/existing time consuming?
Thanks,
Cheers.
--
Stefano Zacchiroli -- Master in Computer Science @ Uni. Bologna, Italy
zack@{cs.unibo.it,debian.org,bononia.it} - http://www.bononia.it/zack/
" I know you believe you understood what you think I said, but I am not
sure you realize that what you heard is not what I meant! " -- G.Romney
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners