small scheduler hack/patch

Marcel Moolenaar marcel at xcllnt.net
Thu Jul 10 15:29:13 PDT 2003


On Thu, Jul 10, 2003 at 03:03:41PM -0700, Julian Elischer wrote:
> 
> it comes I think from the fact that some hardware treats things as
> bitmaps. (?)

I have to guess that a bitmap is a natural way to represent sets
when the sets aren't large and that this is why we use bitmaps.
We have a need to send an IPI to multiple CPUs, which is expressed
nicely with bitmaps.

> there are lots of cases where the code is doing 
> foreach cpu
>  if (cpu->mask & our_mask) 
> 	continue;		/* skip ourself */
> 
> 
> which could easly be 
> if (cpu->number == PCPU_GET(cpu_number))

Agreed.

-- 
 Marcel Moolenaar	  USPA: A-39004		 marcel at xcllnt.net


More information about the freebsd-current mailing list