Messages in this thread |  | | | Date | Thu, 02 Apr 2009 00:07:03 -0700 (PDT) | | Subject | Re: More problems in setup_pcpu_remap() | | From | David Miller <> |
| |
From: Tejun Heo <tj@kernel.org> Date: Thu, 02 Apr 2009 14:55:48 +0900
> David Miller wrote: > > It would make more sense to carve up 2MB chunks into some-power-of-2 > > pieces and use that as the unit size. > > > > You could retain the NUMA goals of this function, as well as the > > ability to be using 2MB pages in the TLBs. > > Can you please elaborate a bit? > > > And consider that if the dynamic allocation part of this code triggers > > even once, you'll end up eating twice as much VMALLOC space. > > > > Using 2MB per cpu is just rediculious, and really not even necessary. > > The focus at the moment is using large page for the first chunk to > reduce pressure on TLB, not necessarily actually using 2MB for each > unit.
You'll get better TLB hit rates with my suggestion.
The idea is to carve up a 2MB page amongst consequetive cpus in the same NUMA node.
With hyperthreading these cpus will be sharing the TLB, so you'll get better TLB hit rates than the current code.
I'm going to do something like this on sparc64. This x86 code is severely demotivating me, so I'll stop looking at it now :-)
|  |