Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Jun 2003 11:54:39 -0700
From:      Marcel Moolenaar <marcel@xcllnt.net>
To:        Jeff Roberson <jroberson@chesapeake.net>
Cc:        Poul-Henning Kamp <phk@phk.freebsd.dk>
Subject:   Re: HyperThreading and CPU topologies.
Message-ID:  <20030612185439.GA543@athlon.pn.xcllnt.net>
In-Reply-To: <20030612142802.W36168-100000@mail.chesapeake.net>
References:  <20030612180335.GA36606@dhcp01.pn.xcllnt.net> <20030612142802.W36168-100000@mail.chesapeake.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jun 12, 2003 at 02:28:52PM -0400, Jeff Roberson wrote:
> 
> On Thu, 12 Jun 2003, Marcel Moolenaar wrote:
> 
> > On Thu, Jun 12, 2003 at 01:45:52PM +0200, Poul-Henning Kamp wrote:
> > > In message <20030612051553.J36168-100000@mail.chesapeake.net>, Jeff Roberson wr
> > > ites:
> > > >Index: smp.h
> > > >===================================================================
> > > >RCS file: /home/ncvs/src/sys/sys/smp.h,v
> > > >retrieving revision 1.72
> > > >diff -r1.72 smp.h
> > > >19a20,46
> > > >>
> > > >> /*
> > > >>  * Topology of a NUMA or HTT system.
> > > >>  *
> > > >>  * The top level topology is an array of pointers to groups.  Each group
> > > >>  * contains a bitmask of cpus in its group or subgroups.  It may also
> > > >>  * contain a pointer to an array of child groups.
> > > >>  *
> > > >>  * The bitmasks at non leaf groups may be used by consumers who support
> > > >>  * a smaller depth than the hardware provides.
> > > >>  *
> > > >>  * The topology may be omitted by systems where all CPUs are equal.
> > > >>  */
> > > >>
> > > >> struct cpu_group {
> > > >>       int     cg_mask;                /* Mask of cpus in this group. */
> > >
> > > u_int ?
> > >
> > > uint32_t ?
> >
> > It's best to make it MD depedendent. I prefer 64-bit masks in ia64.
> >
> 
> I thought I was being consistent with the rest of the file but it turns
> out that it uses u_int so I'm changing to that.  If someone wants to make
> a pass through the smp code and make a cpu_bitmap_t or something they are
> welcome.

I have this on my radar for a while. Mostly because of the PCPU
masks. It's not urgent, so the sweep will not happen anytime soon.
Hence, it's also not a problem if you favor consistency for now.

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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030612185439.GA543>