From: Bill Kelly Date: 2004-07-15T03:54:07+09:00 Subject: system threads (was: Re: No Subject) Hi, From: "ts" > >>>>> "J" == Jesse van den Kieboom writes: > > J> System threads. I don't use threading myself but GTK+ (or pango, I'm not > J> sure) seems to thread. > > ruby don't really like system threads : try to avoid it if you can I'm beginning development of an embedded ruby application, where I want to run ruby in a separate system thread (not the main thread), and run an OpenGL renderer (C/C++) in the main thread. However I plan to never have the main thread call the ruby interpreter directly, or vice-versa. The ruby thread and the renderer thread will communicate via a command queue data structure, with appropriate access synchronization. And data owned by the ruby garbage collector will never be seen by other threads. What I'm wondering is, does this sound like a fairly trouble- free approach? Or am I still stepping into dangerous territory here? I'm hoping that by keeping the ruby thread completely separate from the other thread(s) (except for communication through the queueing mechanism) that I should be safe from thread-related issues with the ruby interpreter. However, if what I'm attempting is already known to be fraught with problems, I'd definitely like to know! :) Thanks for any insight and advice. Regards, Bill