Re: 2.6.14-rt13

From: Steven Rostedt
Date: Fri Nov 18 2005 - 18:58:07 EST




On Fri, 18 Nov 2005, Fernando Lopez-Lezcano wrote:

> > Can it simply be pinned to a cpu?
>
> Is there a way to know in which cpu a process is running? At least Jack
> could ignore timinig issues if the measurement is going to happen in a
> different cpu than the one where the original timestamp was collected.
>

Simple answer? No. At least not meaningfully.

If you do:

cpu = fictitious_get_my_cpu();
if (cpu == last_cpu()) {
rdtsc(oldtime);
...
}

There's no guarantee that jack doesn't switch cpu's from when it found out
what CPU it was on to doing the calculation. So it would be easier to pin
it.

(apt-get schedutils)

man 1 taskset

or if you modify the code:

mn 2 sched_setaffinity

-- Steve



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/