Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

An Opteron 6128 shows up as follows in /proc/cpuinfo:

$ cat /proc/cpuinfo | grep -e ^core -e ^phys 
physical id     : 0
core id         : 0
physical id     : 0
core id         : 1
physical id     : 0
core id         : 2
physical id     : 0
core id         : 3
physical id     : 0
core id         : 0
physical id     : 0
core id         : 1
physical id     : 0
core id         : 2
physical id     : 0
core id         : 3
... (other physical id's)

My understanding so far has been that different cores within the same physical CPU would have different core id, and if core ids are identical, this is due to hyperthreading. So one should interpret this /proc/cpuinfo entry as a 4-core CPU with hyperthreading.

However, Opteron 6128 is really 8-core. What's going on here?

P.S. Full entry for the 8th "processor":

processor       : 7
vendor_id       : AuthenticAMD
cpu family      : 16
model           : 9
model name      : AMD Opteron(tm) Processor 6128
stepping        : 1
cpu MHz         : 800.000
cache size      : 512 KB
physical id     : 0
siblings        : 8
core id         : 3
cpu cores       : 8
apicid          : 23
initial apicid  : 7
fpu             : yes
fpu_exception   : yes
cpuid level     : 5
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc rep_good nonstop_tsc extd_apicid amd_dcm pni monitor cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt nodeid_msr npt lbrv svm_lock nrip_save pausefilter
bogomips        : 3999.89
TLB size        : 1024 4K pages
clflush size    : 64
cache_alignment : 64
address sizes   : 48 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate
share|improve this question
    
Can you please execute cat /proc/cpuinfo without the pipe and also dmidecode and add that info here. Just to check something out. –  Luis Alvarado Jan 12 '13 at 5:34
    
@LuisAlvarado added extra info –  MaxB Jan 12 '13 at 6:35
    
Ok so I can see it detects your 8 cores correctly and your 8 siblings too, weird then by adding the grep it would only show 8 of them and not the ones in thread also. I can only add this article that talks about the different scenarios of cpuinfo: richweb.com/cpu_info –  Luis Alvarado Jan 12 '13 at 7:03
    
@LuisAlvarado Opterons don't really have hyperthreading, I believe. What I don't understand is why, say, this "processor 7" isn't given "core id 7". –  MaxB Jan 12 '13 at 7:33
    
Yeah they don't, in the case of the core id is because it is showing 4 cores for that CPU instead of the 8 it should. Can you cat /proc/cpuinfo | grep cores the full output here. I may be sleepy but I find the question intriguing. –  Luis Alvarado Jan 12 '13 at 7:57
add comment

1 Answer 1

up vote 1 down vote accepted

Here is an Intel i7 2600 to compare with:

cyrex@cyrex:~$ cat /proc/cpuinfo | grep -e ^core -e ^phys
physical id : 0
core id     : 0
physical id : 0
core id     : 1
physical id : 0
core id     : 2
physical id : 0
core id     : 3
physical id : 0
core id     : 0
physical id : 0
core id     : 1
physical id : 0
core id     : 2
physical id : 0
core id     : 3

Since I have an Intel motherboard that only has one socket, this means I only have one physical id. Think of it as for each socket in the motherboard there is one physical id.

Next we have the core ids that reference that physical id. If you look at it, It repeats itself. This is because of the Hyper Threading. There are actually 4 cores and 4 HT ones. So in the end it shows for that one physical id, 4 core ids and 4 HT.

If you have more sockets in your motherboard, the amount of physical IDs will go up along with the amount of cores. In your case it is suppose to show 8 cores (In my case it is 4 cores) so it will show a long list but since it is repeating itself after the 4th core, it looks like is either not reading the other cores (BIOS issue, Kernel issue) or the cpuinfo is not detecting it correctly.

It would also help to find out why if you could execute the following:

sudo dmidecode -t processor | grep -e Core -e Thread and add the information to your question. In my case dmidecode says:

cyrex@cyrex:~$ sudo dmidecode -t processor | grep -e Core -e Thread
    Family: Core i7
    Version: Intel(R) Core(TM) i7-2600 CPU @ 3.40GHz
    Core Count: 4
    Core Enabled: 4
    Thread Count: 8

Also in a benchmark in OpenBenchmark I found your model and there is one line that shows the following when doing cat on /proc/cpuinfo:

cpu cores   : 8

Since in your case it is showing all 8 cores, it means the CPU is detected correctly although the amount of siblings are not all shown. This might be do to how cpuinfo shows this for AMD or that specific family model. If commands like lscpu, dmidecode can show you the amount of CPUs, Cores and threads/siblings for each, then the issue is with how cpuinfo handles the information.

share|improve this answer
    
What do the "cpu cores" lines say in your case? –  MaxB Jan 12 '13 at 5:20
    
@MaxB - In my case it says I have 4 cores (Plus the 4 HT). I am showing there the whole list. As it says 4, then it is correct, at least in my case, not in yours where it should say 8 for what I know about AMD. –  Luis Alvarado Jan 12 '13 at 5:25
    
Re: dmidecode - I'm not root there. –  MaxB Jan 12 '13 at 6:18
    
It looks like there is a similar "bug" in OpenBench: processor : 7 (last core) has core id : 3 instead of 7 –  MaxB Jan 13 '13 at 8:33
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.