[linux-audio-dev] Re: lock-free data structures

New Message Reply About this list Date view Thread view Subject view Author view Other groups

Subject: [linux-audio-dev] Re: lock-free data structures
From: Juhana Sadeharju (kouhia_AT_nic.funet.fi)
Date: Mon Jun 21 2004 - 11:34:53 EEST


>From: Tim Hockin <thockin_AT_hockin.org>
>
>> Quick question: disk thread may suspend if there are no disk use.
>> How the disk thread is woken up to read the lock-free buffer?
>
>Semaphore. Every time you put something into the buffer, up() the

So, one thread for RT-audio, one thread to watch and suspend on
semaphores, and one thread to select() on FDs (for communication
from the application and from the semaphore watcher).

Which one is better?
 (1) RT-audio thread ---> pipe ---> select() thread
 (2) RT-audio thread ---> semaphore --> semaphore watcher thread
        --> pipe --> select() thread

Of course, better for RT-audio thread. While the case (2) is
more complex, it could be better for RT-audio thread.

How this all is done in Ardour? I browsed the source but there are
a lot of stuff there. How about LinuxSampler?

Juhana


New Message Reply About this list Date view Thread view Subject view Author view Other groups

This archive was generated by hypermail 2b28 : Mon Jun 21 2004 - 11:31:04 EEST