On Jan 1, 2004, at 9:43 AM, Josh Wilmes wrote:

At 16:15 on 12/30/2003 EST, Dan Sugalski <[EMAIL PROTECTED]> wrote:

Your constraints:

2) A perl 5 iThreads "it's not a thread, it's a fork. Well, sorta..."
mode must be available

For those of us who aren't particularly familiar with ithreads, what does
this imply? What's different, and why must it be done at the level of
parrot, not perl?

The unique feature of ithreads is that data is not shared between threads by default, but rather has to be marked as shared to be visible from multiple threads. (If you have Perl 5.8, you can read more about this in the perlthrtut man page; in particular, the section "Threads And Data".)


As far as what level needs to implement them, I'd say that parrot has to do enough to make it possible for an HLL to expose ithreads-style threading. Due to the cross-language nature of parrot, practically speaking this probably means that the semantic needs to exist at the parrot level. (For instance, an ithread created in Perl code could load a parrot bytecode library implemented in Python; calling into code inside this library shouldn't allow access to "unshared" data from other ithreads.)

JEff



Reply via email to