Re: [linux-audio-dev] Low latency out-of-process vs in-process .. Re: Low Latency Kernel Combos

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

Subject: Re: [linux-audio-dev] Low latency out-of-process vs in-process .. Re: Low Latency Kernel Combos
From: Paul Davis (pbd_AT_Op.Net)
Date: Thu Jun 07 2001 - 18:43:56 EEST


>> > > Unfortunately Benno, your (and my) intuition is wrong, as shown by the
>> > > testing that Abramo and Steve did about 3 weeks ago.
>
>Mine too! I'm still not quite believing it. It is almost too good
>to be true.

Not really. It just that it takes 100-200 instructions to cause a
context switch, and that the cache effects of doing so vary with the
memory footprint of each process after the switch. If the memory
footprints are small (and we expect them to be), then it works.

If one of the out-of-process clients has a giant memory footprint (by
which we mean merely the memory referenced during the callback, both
data and instruction) then don't expect it to work well, if at
all. Likewise, if you really need the extra 5-10% of the available CPU
cycles used for switching to be available audio processing, then the
cost will be appear too large.

>I have a request. Could someone please write up a little (tiny) document
>that can be posted with the graphs, explaining things better? Basically,
>I want a simple, clear and direct explanation of why it is that the
>out-of-process model works to produce such good results, as compared with
>the in-process model.

Just to clarify, they are not better or even as good as the in-process
model. They are, however, good enough for most scenarios. Its just a
reflection of the fact that the costs of the context switch can be
reasonably contained (in theory, anyway) by sensible application
writing. Think of adding 150 instructions plus a bunch of cache misses
per callback to the in-process case. Not good, for sure, but not that
bad either (as long as those cache misses are limited).

--p


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

This archive was generated by hypermail 2b28 : Thu Jun 07 2001 - 20:06:43 EEST