From: Rusty Russell <rusty@rustcorp.com.au>
To: Avi Kivity <avi@redhat.com>
Cc: "kvm-devel" <kvm@vger.kernel.org>,
linux-kernel@vger.kernel.org, Mike Travis <travis@sgi.com>
Subject: Re: [PATCH 2/2] kvm: use cpumask_var_t for cpus_hardware_enabled
Date: Mon, 8 Dec 2008 16:35:34 +1030 [thread overview]
Message-ID: <200812081635.35166.rusty@rustcorp.com.au> (raw)
In-Reply-To: <493BF206.4070007@redhat.com>
On Monday 08 December 2008 02:25:50 Avi Kivity wrote:
> Rusty Russell wrote:
> > This changes cpus_hardware_enabled from a cpumask_t to a cpumask_var_t:
> > equivalent for CONFIG_CPUMASKS_OFFSTACK=n, otherwise dynamically allocated.
> >
> >
> > -static cpumask_t cpus_hardware_enabled;
> > +static cpumask_var_t cpus_hardware_enabled
>
> This isn't on stack, so it isn't buying us anything.
It's the CONFIG_NR_CPUS=4096 but nr_cpu_ids=4 case which we win using
dynamic allocation. Gotta love distribution kernels.
> Is the plan to drop cpumask_t?
Yes. And undefine 'struct cpumask' if CONFIG_CPUMASK_OFFSTACK. That
will stop assignment and on-stack declarations for all but the most
determined.
> If so, we're penalizing non-stack users
> by forcing them to go through another pointer (and cacheline).
Not quite. If !CONFIG_CPUMASK_OFFSTACK, cpumask_var_t == cpumask_t[1].
Blame Linus :)
Cheers,
Rusty.
next prev parent reply other threads:[~2008-12-08 6:05 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-07 10:55 [PATCH 2/2] kvm: use cpumask_var_t for cpus_hardware_enabled Rusty Russell
2008-12-07 15:55 ` Avi Kivity
2008-12-08 6:05 ` Rusty Russell [this message]
2008-12-08 9:46 ` Avi Kivity
2008-12-08 11:50 ` Rusty Russell
2008-12-08 14:29 ` Mike Travis
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=200812081635.35166.rusty@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=travis@sgi.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.