Re: Question regarding sched_setaffinity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 31 Aug 2008, Karthik Singaram Lakshmanan wrote:

> Hi,
>  I am a noob to SMP real-time scheduling in linux, I have a question of
> sched_setaffinity(). If I restrict an application to a single CPU
> using the appropriate cpumask for sched_setaffinity(), Is it
> guaranteed that the kernel will never schedule it on any other CPU? I
> am asking this because looking at kernel/sched.c seems to use
> cpu_clear during load balancing. I am interested in knowing whether the
> cache will be invalidated when my task is assigned to a single CPU.
> Are there exceptions where the cpu-mask will be overridden?
> Thanks for taking the time to answer my query.

A task should never be scheduled on a CPU that is not in its affinity. 
(although I hear a rumor that if a task is bound to a single CPU, and that 
CPU is taken offline, it will be migrated. But I doubt this is true, since 
there are tasks that would crash the system if this were true).

-- Steve

--
To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux