Jeff Squyres wrote:
> On Apr 24, 2007, at 3:51 AM, Bert Wesarg wrote:
>
>>>> to the processor_id. That can be queried by the api. But to support
>>>> SMT,
>>>> it would be necessary to extend it to a (socket,core,thread) tuple.
>>> I still don't understand this last statement.
>> Ok, if the current (socket,core) plpa code will ever hit a machine
>> with
>> enabled SMT/HTT, or whatever its called today, the code will find
>> multiple
>> (socket,core) tuples for one processor ID and so breaking the ont-
>> to-one
>> mapping. Because a core have threads, and therefor multiple virtual
>> processor ids. But I can't prove it, because I don't have access to
>> such a
>> machine or unless someone sends a cpu topology with enabled HTT/SMT
>> (see
>> the Call for Help message).
>
> Ah, I think I'm starting to understand.
>
> I think you meant to say that a single (socket,core) tuple would map
> to multiple processor ID's.
Yes, see my correction in my self reply.
>
> Regardless, you're right: it breaks the one-to-one mapping.
>
> I have hyper-threading enabled on my lab machines, but they're an
> older kernel (RHEL4U3 -- 2.6.9-based kernel). They're 2 socket Intel
> x86_64 machines, each socket with 2 cores (total of 4 cores).
>
> But I tried to grab the data anyway:
>
> /sys % sudo tar cjf /tmp/cpu-topology.tar.bz2 devices/system/{cpu/
> cpu*/topology/*,node/node*/cpu*}
> tar: devices/system/node/node0/cpumap: File shrank by 4093 bytes;
> padding with zeros
> tar: Error exit delayed from previous errors
>
> Hmm. Got any ideas?
I think, because there is no topology dir in older kernel. from this type
of machines i have two racks full of it but with the same old kernel. And
sudo should't be needed.
>
> My /sys/devices/system/cpu/ has 8 directories (because HT is enabled;
> I never bothered to turn it off): cpu0 through cpu7. Each of those
> directories is empty (assumedly because the kernel is too old).
>
> Since it's a UMA machine, I only have /sys/devices/system/node/
> node0. In there, it has sym links to the 8 cpu* directories and
> three additional files:
>
> /sys/devices/system/node/node0 % ls
> cpu0@ cpu2@ cpu4@ cpu6@ cpumap numastat
> cpu1@ cpu3@ cpu5@ cpu7@ meminfo
>
> Here's the contents of those three files:
>
> /sys/devices/system/node/node0 % cat cpumap
> ff
> /sys/devices/system/node/node0 % cat meminfo
> Node 0 MemTotal: 5242880 kB
> Node 0 MemFree: 278968 kB
> Node 0 MemUsed: 4963912 kB
> Node 0 Active: 1285488 kB
> Node 0 Inactive: 2031128 kB
> Node 0 HighTotal: 0 kB
> Node 0 HighFree: 0 kB
> Node 0 LowTotal: 5242880 kB
> Node 0 LowFree: 278968 kB
> Node 0 HugePages_Total: 0
> Node 0 HugePages_Free: 0
> /sys/devices/system/node/node0 % cat numastat
> numa_hit 3705213152
> numa_miss 0
> numa_foreign 0
> interleave_hit 383843
> local_node 3705213152
> other_node 0
>
|