lkml.org 
[lkml]   [2003]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [patch] Re: Bug 619 - sched_best_cpu does not pick best cpu (1/1)
Date
On Wednesday 14 May 2003 20:26, Zwane Mwaikambo wrote:
> On Wed, 14 May 2003, Andrew Theurer wrote:
> > +int nr_cpus_in_node[MAX_NUMNODES] = { [0 ... (MAX_NUMNODES -1)] = 0};
>
> [snip...]
>
> > +static inline int nr_cpus_node(int node)
> > +{
> > + return nr_cpus_in_node[node];
> > +}
> > +
> > static inline int cpu_to_node(int cpu)
> > {
> > int node;
>
> How about an hweight() on node_to_cpumask?

I'd rather cache it. I believe hweight() will be the asm-generic routine.

-Andrew

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:35    [W:0.101 / U:0.392 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site