On Wed, Dec 27, 2006 at 03:12:51AM -0800, Martin Knoblauch wrote:
>  What I now need is the output from 2.4 based configs. Only multi-core
> and/or HT-enabled systems actually.

AFAIK in vanilla kernel 2.4 there is no way to tell between virtual and real 
CPUs from /proc/cpuinfo as can be seen by the following examples :

HW: Dual CPU 2.66GHz, HT enabled
SW: MDK 9.1 with a recompiled 2.4.21 kernel with ACPI_HT_ONLY=y

processor       : 0
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.66GHz
stepping        : 9
cpu MHz         : 2665.947
cache size      : 512 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm
bogomips        : 5321.52

processor       : 1
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.66GHz
stepping        : 9
cpu MHz         : 2665.947
cache size      : 512 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm
bogomips        : 5321.52

processor       : 2
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.66GHz
stepping        : 9
cpu MHz         : 2665.947
cache size      : 512 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm
bogomips        : 5321.52

processor       : 3
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.66GHz
stepping        : 9
cpu MHz         : 2665.947
cache size      : 512 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm
bogomips        : 5321.52

HW: Dual CPU 2.8GHz, HT enabled
SW: MDK 9.1 with a custom compiled 2.4.32 kernel and booted with "acpi=ht"

processor       : 0
vendor_id       : GenuineIntel
cpu family      : 15
model           : 4
model name      : Intel(R) Xeon(TM) CPU 2.80GHz
stepping        : 10
cpu MHz         : 2800.242
cache size      : 16 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 5
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor
ds_cpl cid
bogomips        : 5583.66

processor       : 1
vendor_id       : GenuineIntel
cpu family      : 15
model           : 4
model name      : Intel(R) Xeon(TM) CPU 2.80GHz
stepping        : 10
cpu MHz         : 2800.242
cache size      : 16 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 5
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor
ds_cpl cid
bogomips        : 5596.77

processor       : 2
vendor_id       : GenuineIntel
cpu family      : 15
model           : 4
model name      : Intel(R) Xeon(TM) CPU 2.80GHz
stepping        : 10
cpu MHz         : 2800.242
cache size      : 16 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 5
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor
ds_cpl cid
bogomips        : 5596.77

processor       : 3
vendor_id       : GenuineIntel
cpu family      : 15
model           : 4
model name      : Intel(R) Xeon(TM) CPU 2.80GHz
stepping        : 10
cpu MHz         : 2800.242
cache size      : 16 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 5
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm pni monitor
ds_cpl cid
bogomips        : 5596.77

at boot time though, there is a "Physical Processor ID" field during 
initialization that tells them apart as shown by the following log excerpt 
from boot time:

kernel: Initializing CPU#0
kernel: CPU: Trace cache: 12K uops, L1 D cache: 8K
kernel: CPU: L2 cache: 512K
kernel: CPU: Physical Processor ID: 0
kernel: Intel machine check reporting enabled on CPU#0.
kernel: CPU: Trace cache: 12K uops, L1 D cache: 8K
kernel: CPU: L2 cache: 512K
kernel: CPU: Physical Processor ID: 0
kernel: Intel machine check reporting enabled on CPU#0.
kernel: CPU0: Intel(R) Xeon(TM) CPU 2.66GHz stepping 09
kernel: per-CPU timeslice cutoff: 1463.11 usecs.
kernel: enabled ExtINT on CPU#0
kernel: Initializing CPU#1
kernel: masked ExtINT on CPU#1
kernel: CPU: Trace cache: 12K uops, L1 D cache: 8K
kernel: CPU: L2 cache: 512K
kernel: CPU: Physical Processor ID: 0
kernel: Intel machine check reporting enabled on CPU#1.
kernel: CPU1: Intel(R) Xeon(TM) CPU 2.66GHz stepping 09
kernel: Initializing CPU#2
kernel: masked ExtINT on CPU#2
kernel: CPU: Trace cache: 12K uops, L1 D cache: 8K
kernel: CPU: L2 cache: 512K
kernel: CPU: Physical Processor ID: 3
kernel: Intel machine check reporting enabled on CPU#2.
kernel: CPU2: Intel(R) Xeon(TM) CPU 2.66GHz stepping 09
kernel: Initializing CPU#3
kernel: masked ExtINT on CPU#3
kernel: CPU: Trace cache: 12K uops, L1 D cache: 8K
kernel: CPU: L2 cache: 512K
kernel: CPU: Physical Processor ID: 3
kernel: Intel machine check reporting enabled on CPU#3.
kernel: CPU3: Intel(R) Xeon(TM) CPU 2.66GHz stepping 09
kernel: ..... CPU clock speed is 2665.8702 MHz.

RHEL 3 (at least the 2.4.22 nptlsmp AS kernel) do show "physical id" and 
"siblings" fields though as shown by :

processor       : 0
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.40GHz
stepping        : 5
cpu MHz         : 2399.345
cache size      : 512 KB
physical id     : 0
siblings        : 2
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov 
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe cid
runqueue        : 0

bogomips        : 4784.12

processor       : 1
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.40GHz
stepping        : 5
cpu MHz         : 2399.345
cache size      : 512 KB
physical id     : 0
siblings        : 2
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov 
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe cid
runqueue        : 0

bogomips        : 4797.23

processor       : 2
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.40GHz
stepping        : 5
cpu MHz         : 2399.345
cache size      : 512 KB
physical id     : 3
siblings        : 2
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe cid
runqueue        : 2

bogomips        : 4797.23

processor       : 3
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Intel(R) Xeon(TM) CPU 2.40GHz
stepping        : 5
cpu MHz         : 2399.345
cache size      : 512 KB
physical id     : 3
siblings        : 2
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe cid
runqueue        : 2

bogomips        : 4797.23

another architecture were this count might be as well important is on SPARC,
but I have no Niagara running Linux to take a peak yet, and it might be as
well work with the current logic from 2.6.

Carlo

Reply via email to