atom feed13 messages in at.iem.pd-devclock function thread safety - was Re...
FromSent OnAttachments
guenter geigerJun 2, 2003 6:09 am 
Thomas GrillJun 2, 2003 7:04 am 
Frank BarknechtJun 2, 2003 8:04 am 
Frank BarknechtJun 2, 2003 8:06 am 
Frank BarknechtJun 2, 2003 8:07 am 
guenter geigerJun 2, 2003 8:21 am 
Miller PucketteJun 2, 2003 8:53 am 
guenter geigerJun 2, 2003 9:19 am 
Frank BarknechtJun 2, 2003 10:05 am 
chris clepperJun 2, 2003 11:00 am 
Thomas GrillJun 2, 2003 11:59 am 
Miller PucketteJun 2, 2003 3:26 pm 
Miller PucketteJun 2, 2003 3:29 pm 
Subject:clock function thread safety - was Re: [PD-dev] devel_0_37 branch
From:Miller Puckette (mpuc@man104-1.ucsd.edu)
Date:Jun 2, 2003 8:53:50 am
List:at.iem.pd-dev

What's wrong with simply putting a mutex around all of Pd? that way other threads could just make calls right into "receive" objects without having to set and wait for clock callbacks. Perhaps I'm missing something but that seems the much simpler solution for making threaded externs.

Pd's scheduler would simply lock all pf Pd whenever it issues a message or runs a DSP tick, and unlock it when it ``idles".

cheers Miller

On Mon, Jun 02, 2003 at 04:04:26PM +0200, Thomas Grill wrote:

Hi Günter,

I just opened the devel_0_37 branch on CVS. There are not too many differences between Millers version and this one.

great!

If an important feature is missing (some of Thomas threading stuff ??) please let us discuss it.

Well, at least it's important for me, because in my externals (and i think to recall also in Olaf's) the clock functions are used for inter-thread-communication. For this to work reliably they have to be thread-safe. I think that this is the only possibility for threads in PD to communicate with the real-time-system. I implemented the necessary things in devel_0_36, so i would like to know if anyone had problems with it (like timing hickups, deadlocks, clicks etc.). I use this version on a regular basis and haven't encountered problems lately. Therefore, it would be great if we could merge it into the devel_0_37 branch.

best greetings, Thomas