Pth thread in extension

I tried to pth_spawn a thread in an extension library.
The thread only runs if I pth_sleep in the method that
spawns the thread, but I’d like to return to the ruby
interpreter immediately and concurrently do other things.
I also tried it all in C and everything works ok there.
Is there anything I could do that would allow the pth
thread to run freely? I tried pth_yield and calling
method from a ruby level Thread.new but no luck yet.
I could fork another process for the threads but then it’s
not as convenient to communicate. I’m using NetBSD 1.6
and pth 1.4.1.
Bob

Hi,

···

At Wed, 29 Jan 2003 04:22:59 +0900, anderson wrote:

Is there anything I could do that would allow the pth
thread to run freely? I tried pth_yield and calling
method from a ruby level Thread.new but no luck yet.

Current implementation is not native thread safe. There is no
chance to work.


Nobu Nakada