From: Clark Williams <clark.williams@gmail.com>
To: Aaron Fabbri <ajfabbri@gmail.com>
Cc: John Kacur <jkacur@redhat.com>, linux-rt-users@vger.kernel.org
Subject: Re: [patch] cyclictest: CPU affinity now takes arbitrary set of cpus.
Date: Wed, 11 Dec 2013 15:35:06 -0600 [thread overview]
Message-ID: <20131211153506.1e51328c@sluggy> (raw)
In-Reply-To: <CAF+KLxtyOC7jWcnr1XoF6Su3LeywYpVq5Sac258mUJ9hGrEtKA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1652 bytes --]
On Thu, 5 Dec 2013 16:29:37 -0800
Aaron Fabbri <ajfabbri@gmail.com> wrote:
> [This patch is rebased on latest rt-tests.git, and is available in the
> "delivery" branch at https://github.com/ajfabbri/af-rt-tests.git]
>
> Change -a (affinity) option to take a set of CPUs, instead of just one.
>
> e.g.
> cyclictest -a4,6-8 -t5
>
> will use 5 threads, assigned round-robin to the set of CPUs {4,6,7,8}.
> CPU 4 will get threads 1 and 5, CPU 6 gets thread 2, CPU 7 gets thread 3, and
> CPU 8 gets thread 4.
>
> Although this builds without libnuma, libnuma >= v2 is required for these
> arbitrary CPU sets. With libnuma v1, the -a option behaves as before. As
> before, compiling without libnuma is supported. The command usage help is fixed
> up at compile time to always show the correct usage of the -a option.
>
> Also note that, since numa_parse_cpustring_all() wasn't available in early
> libnuma v2 versions, we use numa_parse_cpustring(). This means you'll have to
> use taskset in some cases (isolcpus kernel parameter) to add the desired CPUs to
> the set of allowed cores, e.g.:
>
> taskset -c4-6 cyclictest -a4-6
>
> Tested without libnuma (numactl), and with versions 1.0.2 and 2.0.9-rc3.
>
> Signed-off-by: Aaron Fabbri <ajfabbri@gmail.com>
Thanks, I cherry-picked the commit from your git tree (the included
patch was too badly line-wrapped for me to use it). The only issue I've
seen so far was that in display_help() your #endif picked up the -A
option which is not dependent on libnuma behavior, so I fixed that up.
I'll do some testing and push a new rt-tests out soon.
Clark
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2013-12-11 21:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-06 0:29 [patch] cyclictest: CPU affinity now takes arbitrary set of cpus Aaron Fabbri
2013-12-11 21:35 ` Clark Williams [this message]
2013-12-13 2:57 ` Aaron Fabbri
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131211153506.1e51328c@sluggy \
--to=clark.williams@gmail.com \
--cc=ajfabbri@gmail.com \
--cc=jkacur@redhat.com \
--cc=linux-rt-users@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).