Bound Threads

Alastair Reid alastair at reid-consulting-uk.ltd.uk
Fri Mar 21 09:22:33 EST 2003


Daan writes:
> What I mostly wanted to ensure is that people have really thought
> about this carefully and that they could give strong reasons for
> choosing a particular design over another.

SimonPJ replies:
> The difficulty is that I can't give strong reasons for choosing X
> over Y when I don't understand what Y is.  Next week is ok though.

I think the essence of Daan's proposal was that the goals we hope to
achieve using 'bound', 'threadsafe', and other ffi annotations could 
be achieved by adding a small amount of additional functionality
and wrappers and that benefits of doing this are:

- greater transparency to programmers 
- greater flexibility because those primitives can be used in many
  different ways
- more future-proof because of greater flexibility
- simpler design

Some inspiration for this approach might be found in the move from
GreenCard to the standard FFI.  GreenCard gives you some important
functionality that covers many cases you might want but, since it
doesn't cover _everything_ you want to do, we've seen a gradual
addition of features over the years as the shoe is made to pinch a
little less.

I think the details of which operations to add were largely intended
to show that this kind of approach was plausible rather than being
intended as a complete proposal.

[Personally, I'm not sure that Daan is right - but I think it's worth
exploring a little.]

--
Alastair Reid                 alastair at reid-consulting-uk.ltd.uk  
Reid Consulting (UK) Limited  http://www.reid-consulting-uk.ltd.uk/alastair/





More information about the FFI mailing list