All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Kacur <jkacur@redhat.com>
To: Valentin Schneider <vschneid@redhat.com>
Cc: linux-rt-users@vger.kernel.org
Subject: Re: [PATCH] rteval: Fix loads cpulist restriction
Date: Fri, 5 Aug 2022 13:39:49 -0400 (EDT)	[thread overview]
Message-ID: <e56b7aa-347b-b446-d6e-31b0ec10e693@redhat.com> (raw)
In-Reply-To: <xhsmh5yj6d28f.mognet@vschneid.remote.csb>



On Fri, 5 Aug 2022, Valentin Schneider wrote:

> On 05/08/22 13:04, John Kacur wrote:
> > On Fri, 5 Aug 2022, Valentin Schneider wrote:
> >
> >> On 05/08/22 14:42, Valentin Schneider wrote:
> >> > A recent batch of commits, one of them being:
> >> >
> >> >   39115f0a826d ("rteval: Make use of systopology instead of misc in hackbench")
> >> >
> >> > has made the loads modules use CpuList.expand_cpulist() (which produces a
> >> > list(int)) instead of misc.expand_cpulist() (which produces a list(str)).
> >> > However, the bits handling restricting CPU affinity based on a user
> >> > argument still expects to handle a list(str), which results in:
> >> >
> >> >   [DEBUG] [kcompile] node 0 has no available cpus, removing
> >> >   [...]
> >> >   [DEBUG] [hackbench] node 0 has no available cpus, removing
> >> >
> >>
> >> This is lacking some context, so here's more:
> >>
> >> This was triggered on an arm64 system (Ampere eMAG), any sort of affinity
> >> restriction suffices, e.g.
> >>
> >>  $ rteval -O -D -v --loads-cpulist=2-3
> >>
> >> I can reproduce that on my x86 laptop:
> >>
> >>   $ sudo ./rteval-cmd -O -D -v --loads-cpulist=2-3
> >>   [DEBUG] [kcompile] systopology: 1 node system (8 cores per node)
> >>   [DEBUG] [kcompile] node 0 has no available cpus, removing
> >>   [DEBUG] [kcompile] node 0 has no available cpus, removing
> >>   [DEBUG] [hackbench] node 0 has no available cpus, removing
> >>
> >>
> > Thanks
> > Signed-off-by: John Kacur <jkacur@redhat.com>
> >
> > re python sets for cpu (cpuset is an overloaded term)
> > The idea isn't bad it could work.
> >
> > Right now I am trying reduce the number of duplicated interfaces.
> > Even a seemingly simple change to use lists of ints instead of lists of
> > strings of ints can uncover problems. So, I probbaly would not be so open
> > to python sets for cpus at the moment, but could be in the future.
> >
> > It is probably more work than you realize though, and I would require a
> > full solution, which means replacing the uses of the current interfaces in
> > cyclictest (measurement module), kcompile, hackbench, stressng. You could
> > create a personal fork and have a go at it though if you like!
> >
> 
> I think I'll tinker with a new class and figure out what features it would
> need, and then I'll sit on it and push it further down my todolist - like
> you said, the primary ingredient here is gonna be time :)
> 
> 
Also, CpuList was really just designed as a helper class to SysTopology 
and not really mean as a general interface. I do have plans to separate 
some of that functionality out into a more generic interace we can use.
It might make more sense at that time, to start thinking about whether 
sets would work better or not. So, like anything open source, you're 
welcome to play with it, but you might want to chat with me a little if 
you're serious about it, we could maybe hash out a coherent plan.

John


      reply	other threads:[~2022-08-05 17:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-05 13:42 [PATCH] rteval: Fix loads cpulist restriction Valentin Schneider
2022-08-05 14:43 ` Valentin Schneider
2022-08-05 14:54   ` Clark Williams
2022-08-05 17:04   ` John Kacur
2022-08-05 17:33     ` Valentin Schneider
2022-08-05 17:39       ` John Kacur [this message]

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=e56b7aa-347b-b446-d6e-31b0ec10e693@redhat.com \
    --to=jkacur@redhat.com \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=vschneid@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.