Re: [Jack-Devel] How does jackdmp set CPU affinity ?

PrevNext  Index
DateThu, 07 Jul 2011 16:20:56 -0500
From karthik poduval <[hidden] at gmail dot com>
ToStéphane Letz <[hidden] at grame dot fr>
Cc[hidden] at lists dot jackaudio dot org
In-Reply-ToStéphane Letz Re: [Jack-Devel] How does jackdmp set CPU affinity ?
Follow-UpPaul Davis Re: [Jack-Devel] How does jackdmp set CPU affinity ?
Follow-UpStéphane Letz Re: [Jack-Devel] How does jackdmp set CPU affinity ?
Thanks a lot for the prompt reply Stéphane.

Please correct me if my understanding is incorrect.

Let me refer to Figure 1 in
http://www.grame.fr/Ressources/pub/Jackdmp-lac2005.pdf. Once client Input's
out ports are filled, it signals both  A and B by signalling their
JackSynchro objects. A and B  may run on different CPU's as the actual CPU
assignment is managed by the underlying Linux scheduler. After A and B
complete, both try to Signal client C, however client C only gets signalled
only once its activation counter gets decremented twice and reaches the
expected value.

I have not studied jack1, but was this scenario serialized in jack1 ? Would
jack1 have signal client A which would run and then signal client B which
would run and then signal client C ?

Regards,
Karthik Poduval


On Thu, Jul 7, 2011 at 3:57 PM, Stéphane Letz <[hidden]> wrote:

>
> Le 7 juil. 2011 à 22:50, karthik poduval a écrit :
>
> > Hi All,
> >
> > I have been reading about jackdmp and how it can run client process
> callbacks(that are independent) on different cpu's on an smp machine from
> this document.
> > http://www.grame.fr/Ressources/pub/Jackdmp-lac2005.pdf
> >
> > I had a couple of questions about it.
> >
> > 1. How does jackdmp assign a process callback thread to a given CPU ? I
> was expecting a call to pthread_setaffinity somewhere in the code but did
> not find it being used.
>
> Is does not. What jack2 does is a "data flow like" client graph activation
> model, then use the regular scheduler without any more tricks.
>
> >
> > 2. From which version of jack2 is this mp feature enabled ? I am using
> jack1.9.5, is this version mp capable ?
>
> From jackdmp "day one" (back in 2005)
>
> >
> > 3. Do I need to specify any command line option while starting the jackd
> to enable this feature or perhaps set some command line option to waf while
> compiling it  ?
>
> Nope.
>
> >
> > I am running jackd on a Linux machine that runs a Fedora 12 distro. The
> CPU is a dual core Intel Atom (Intel(R) Atom(TM) CPU D510   @ 1.66GHz).
> >
> > I checked the cpu assignment for jackd and its clients using the ps
> command and found the cpu assignment to vary every time I ran the command.
> >
> >
> > 2853   1  FF     10  50   - jackd -dalsa -P
> > 2857   1  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro (This time all threads on
> CPU1)
> >
> > 2853   0  FF     10  50   - jackd -dalsa -P
> > 2857   0  FF      5  45   - jack_multiple_metro
> > 2857   0  FF      5  45   - jack_multiple_metro
> > 2857   0  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro
> > 2857   1  FF      5  45   - jack_multiple_metro (2 threads on CPU 1 and 4
> on CPU0)
> >
> >
>
> Yep. No CPU affinitiy.
>
> Stéphane




-- 
Regards,
Karthik Poduval
PrevNext  Index

1310073687.3977_0.ltw:2,a <CAFP0Ok9pC+P-UruMdoSm7kkhtApiBh=SJw+Zc5Jx0o5J4_htYQ at mail dot gmail dot com>