From: Peter Zijlstra <peterz@infradead.org>
To: K Prateek Nayak <kprateek.nayak@amd.com>
Cc: Steve Wahl <steve.wahl@hpe.com>, Russ Anderson <rja@hpe.com>,
Dimitri Sivanich <sivanich@hpe.com>,
Ingo Molnar <mingo@redhat.com>,
Juri Lelli <juri.lelli@redhat.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
Dietmar Eggemann <dietmar.eggemann@arm.com>,
Steven Rostedt <rostedt@goodmis.org>,
Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
Valentin Schneider <vschneid@redhat.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] sched/topology: improve topology_span_sane speed
Date: Tue, 15 Oct 2024 13:05:44 +0200 [thread overview]
Message-ID: <20241015110544.GQ16066@noisy.programming.kicks-ass.net> (raw)
In-Reply-To: <60473622-e6f9-561b-a269-9da64add4966@amd.com>
On Tue, Oct 15, 2024 at 03:50:49PM +0530, K Prateek Nayak wrote:
> > + masks = kmalloc_array(num_possible_cpus(), sizeof(struct cpumask *), GFP_KERNEL);
> > + if (!masks)
> > + return ret;
>
> That looks like a very large array that seems unnecessary. Instead, is
> it possible to use "tl->mask(id)" down blow to check for equality? (I'll
> elaborate more below)
drive-by comments, haven't got time atm to read this, but
num_possible_cpus() is wrong, this should be nr_cpu_ids.
The CPU mask must not be assumed dense.
next prev parent reply other threads:[~2024-10-15 11:05 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-10 15:51 [PATCH] sched/topology: improve topology_span_sane speed Steve Wahl
2024-10-15 10:20 ` K Prateek Nayak
2024-10-15 11:05 ` Peter Zijlstra [this message]
2024-10-15 22:32 ` Steve Wahl
2024-10-15 22:19 ` Steve Wahl
2024-10-15 14:37 ` Valentin Schneider
2024-10-16 8:10 ` Valentin Schneider
2024-10-16 16:08 ` Steve Wahl
2024-10-25 15:06 ` Steve Wahl
2024-10-25 17:21 ` Valentin Schneider
2024-10-18 11:35 ` Vishal Chourasia
2024-10-21 16:20 ` Steve Wahl
2024-10-23 13:19 ` Vishal Chourasia
2024-10-23 15:16 ` Shrikanth Hegde
2024-10-29 17:34 ` samir
2024-11-01 20:05 ` Steve Wahl
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=20241015110544.GQ16066@noisy.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=bsegall@google.com \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@redhat.com \
--cc=kprateek.nayak@amd.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=rja@hpe.com \
--cc=rostedt@goodmis.org \
--cc=sivanich@hpe.com \
--cc=steve.wahl@hpe.com \
--cc=vincent.guittot@linaro.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox