Re: Bytecode level thread implementation

Tomasz Zielonka <t.zielonka@zodiac.mimuw.edu.pl>
30 May 2004 13:23:47 -0400

          From comp.compilers

Related articles
Bytecode level thread implementation darkbard@extending-php.net (Gabriele Farina *DarkBard*) (2004-05-24)
Re: Bytecode level thread implementation t.zielonka@zodiac.mimuw.edu.pl (Tomasz Zielonka) (2004-05-30)
Re: Bytecode level thread implementation eliotm@pacbell.net (Eliot Miranda) (2004-05-30)
| List of all articles for this month |
From: Tomasz Zielonka <t.zielonka@zodiac.mimuw.edu.pl>
Newsgroups: comp.compilers
Date: 30 May 2004 13:23:47 -0400
Organization: MIMUW
References: 04-05-064
Keywords: interpreter
Posted-Date: 30 May 2004 13:23:47 EDT

Gabriele Farina *DarkBard* wrote:
> I'd like to implement a OS independent threading system. I thought to
> manage threads directly inside the bytecode genereted by my compiler.
> Do you think it could be interesting? There's any opensource language
> that implements this kind of feature?


This is a known idea. It works quite well, so expect to find many such
implementations.


Check Erlang and byte-code compiled OCaml.


IIRC, You can use this kind of threading system in some Java
implementations.


Haskell compiler GHC uses user-level threading for both byte-code and
native-code. Task switching happens when the program allocates memory
(Haskell programs tend to allocate quite often) or uses concurrency
primitives.


Best regards,
Tom


--
.signature: Too many levels of symbolic links


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.