Phil,

I think you're jumping the gun here. "GIL"-style threading will
require extensive changes to the VM. A first step is to move
co-operative thread scheduling out of the library and into the VM.
Second, we need to remove the ability to pass byte arrays to FFI
functions (since FFI calls release the lock, any other Factor thread
can come along and run a GC, moving the byte array), and update all
usages of the FFI for this. I'd prefer to do these changes myself.

Instead, maybe you could finish what you started with multi-VM
threading. The VM startup/shutdown APIs need to be redone and cleaned
up (Doug's work is a good first approximation). There needs to be easy
APIs for spawning new VMs from the Factor side (passing in a
quotation; a list of command line args doesn't cut it). There needs to
be easy ways of communicating between VMs with serialized objects.

Slava

On Wed, Oct 21, 2009 at 2:50 PM, Phil Dawes <[email protected]> wrote:
> Hi everyone,
>
> I did a bit of thinking about how a GIL could be implemented on my way
> home from work today. I've turned my notes into a blog post:
>
> http://phildawes.net/blog/2009/10/21/factor-gil-lock-idea/
>
> (I'm trying to get into the habit of blogging frequently)
>
> Does this sound like a reasonable approach or is there something obvious
> I'm missing?
>
> Cheers,
>
> Phil
>
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
> _______________________________________________
> Factor-talk mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/factor-talk
>

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Factor-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to