Re: IOProc limitations
Re: IOProc limitations
- Subject: Re: IOProc limitations
- From: James McCartney <email@hidden>
- Date: Tue, 19 Jun 2001 14:22:04 -0500
on 5/31/01 7:44 PM, Jeff Moore at email@hidden wrote:
>
I'd refer to the source code in Darwin for this info. I couldn't tell you
>
offhand whether it does or not. But regardless, you _really_ ought not block
>
the IOThread on a mutex that some other thread may have. You will get very
>
bad results since the HAL will treat you as if you are CPU bound and you
>
will get lots of internal resynchs. In other words, you will get break up
>
and distortion.
Just to get back to this. If OSX did the proper priority inversion like a
good real time OS, then blocking the IOProc on a mutex would have no ill
effects. What would happen is that you would immediately switch to the
thread holding the lock, it could do its thing and release the lock, then
you would switch back to the IOProc. It would cost two thread switches, but
otherwise it would be just like a function call and the IOProc would
continue without problem.
--- james mccartney email@hidden <
http://www.audiosynth.com>
SuperCollider - a real time synthesis programming language for the PowerMac.
<
ftp://www.audiosynth.com/pub/updates/SC2.2.10.sea.hqx>