[PATCH 0/6] Affinity devel and fixes

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

 



These are changes to improve affinity on cyclictest

There are some fixes to the parsing of -a CPUSET that occurred in a few
exceptional instances.

Also, cyclictest was written as if it owned the whole machine. So before
these changes we would run on all cpus or on the CPUSET that the user
passed with the command line option even if those cpus were not in the
CPUSET from the affinity in the runtime environment. These changes here
fix that. For example,

Before the changes
taskset 4-7 cyclictest -t -a 1-6
the taskset 4-7 would only apply to the main cyclictest thread, and then
the 1-6 would only apply to every newly created thread.

After the changes
taskset 4-7 cyclictest -t -a 1-6
Now, 4-7 still applies to the main thread, but all newly created threads
run on the interesection of the cpus 4-7 and 1-6, in other words on 4,5
and 6

In addition if the user doesn't pass and affinity with the command line
option, the runtime environment is respected.

For example

Before
taskset 0-4 cyclictest -t
Only the main cyclictest thread would run on cpus 0-4 and the other
threads could run on any cpu

After
taskset 0-4 cyclictest -t
All cyclictest threads run on 0-4


John Kacur (6):
  rt-tests: cyclictest: Set errno to 0 before call to mlock
  rt-tests: cyclictest: Report all errors from pthread_setaffinity_np
  rt-tests: cyclictest: Fix parsing affinity with a space and a leading
    zero
  rt-tests: cyclictest: Fix parsing affinity with leading exclamation
    mark
  rt-tests: cyclictest: Only run on available cpus according to the
    affinity
  rt-tests: cyclictest: Only run on runtime affinity and user supplied
    affinity

 src/cyclictest/cyclictest.c | 78 +++++++++++++++++++++++++++++++++----
 1 file changed, 71 insertions(+), 7 deletions(-)

-- 
2.20.1




[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