From: "Stéphane Glondu" <steph@glondu.net>
To: Christophe Raffalli <christophe.raffalli@univ-savoie.fr>
Cc: Caml List <caml-list@yquem.inria.fr>
Subject: Re: [Caml-list] Closures serialization and hash.
Date: Mon, 15 Apr 2013 15:21:47 +0200 [thread overview]
Message-ID: <516BFEEB.2060508@glondu.net> (raw)
In-Reply-To: <516BC56B.7090903@univ-savoie.fr>
Le 15/04/2013 11:16, Christophe Raffalli a écrit :
> - use a table associating function "names" (position in the .cmo, or the lambda-tree or anything
> portable) to source code adresses. The function name should be portable across architecture and
> distinct binary using common librairies.
>
> - (1) fill this table by calling a function "register_code_pointer : ('a -> 'b) -> unit"
Instead of letting the compiler guessing a portable name, I'd rather
give explicit names to code pointers. Like Callback.register in the FFI.
You'd also get the possibility to maintain ABI stability.
> - (2) or even better offer a linking option to register all closures from some compilation unit.
I'm not convinced this is better. I don't think having the possibility
to serialize /any/ closure is a good thing. IMHO, serialized functions
are like exported functions in modules. Their stability should be
guaranteeable at ABI level, which is not something you want for everything!
Cheers,
--
Stéphane
next prev parent reply other threads:[~2013-04-15 13:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-15 9:16 Christophe Raffalli
2013-04-15 13:21 ` Stéphane Glondu [this message]
2013-04-15 20:59 ` Gerd Stolpmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=516BFEEB.2060508@glondu.net \
--to=steph@glondu.net \
--cc=caml-list@yquem.inria.fr \
--cc=christophe.raffalli@univ-savoie.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox