core id repeated on Opteron 6100 processors
The Opteron 6100 series are physically two multi-core CPUs on the same socket and the "core id:" field in cpuinfo is reused between CPUs, resulting in VanillaCpuLayout.fromCpuInfo() incorrectly counting them as multiple thread units for the same core.
Contents of /proc/cpuinfo: https://gist.github.com/2209193
Can you see a way to tell that are different cores and not different threads on the same core? It appears to me that the cpuinfo is incorrect. :P
It's certainly not sufficient for your purpose, anyway. I've had better luck using hwloc/lstopo from OpenMPI to get physical layout information, maybe you could leverage that somehow instead?
Do you have any example code or references for these functions?
BTW: You can provide your own "cpuinfo" file which contains the information which needs to be there.