The "about this mac" is reporting physical cores. When you use something like activity monitor it shows all 4 logical cores.
You can write a pretty straightforward CPUID program to see the actual CPU info if you want.
Thanks. I was finally able to sort it all out based on the information you and others provided here.
Just as an aside, I set my engine up against the latest Crafty version for 20 5 min blitz games. I am not sure why I did this, because I have been working my way up from lesser engines and making coding changes where needed. I guess it was morbid curiosity. Crafty beat my engine in all 20 games.
So now, back to working my way up the ranks and making the changes as needed.
Yes, as far as chess programs are concerned. One typically wants the number of threads used for searching to equal the number of physical cores.
Why?
HT actually works. Of course 4 threads on 2 real cores × HT would not be as fast as on 4 real cores but it will be faster than 2 threads on 2 real cores without HT.
The "about this mac" is reporting physical cores. When you use something like activity monitor it shows all 4 logical cores.
You can write a pretty straightforward CPUID program to see the actual CPU info if you want.
Thanks. I was finally able to sort it all out based on the information you and others provided here.
Just as an aside, I set my engine up against the latest Crafty version for 20 5 min blitz games. I am not sure why I did this, because I have been working my way up from lesser engines and making coding changes where needed. I guess it was morbid curiosity. Crafty beat my engine in all 20 games.
So now, back to working my way up the ranks and making the changes as needed.
Jeff
I've spent some time trying to develop a "topology map" that Crafty can use. I'd like to know which physical cores are on the same cpu chip so that they share the same L3 cache and same bank of memory (since multi-cpu chip boxes are all NUMA nowadays). I want to try to optimize which threads use which cpus and that shallow splits are done between threads sharing the same local memory and L3.
Turns out to be a gigantic pain in the ass however. Operating systems don't enumerate processors the same way. One linux box I have enumerates 12 physical/24 logical cores as 0-11 physical, 12-23 logical processors that map 1-1 with physical cores 0-11, so 0-12, 1-13, etc. And I think "Aha, this will work." Then along comes apple and numbers the physical cores 0 and 2, and the corresponding logical cores 1-3. And then there are systems that use the APICID, which doesn't map 'em into consecutive numbers at all.
I finally thought "hell with it right now, too much inconsistency" I started to use the CPUID (which is painful and you have to force your thread onto each individual CPU to get its hardware numbering. But then it turns out the software can change that anyway. So again "hell with it."
Be nice if we had some sort of POSIX standard for topology and a corresponding library function that works everywhere. And notice I didn't even mention Micro$oft.
syzygy wrote:A logical core is not a physical processor core.
If your OS is not broken, then you have two physical cores. With an i7 this seems only possible if it is a relatively old (2010) mobile "Arrandale" cpu. However these do not go faster than 2.66 Ghz (maybe turboboost can make them reach 3.0 Ghz, I am not sure).
syzygy wrote:A logical core is not a physical processor core.
If your OS is not broken, then you have two physical cores. With an i7 this seems only possible if it is a relatively old (2010) mobile "Arrandale" cpu. However these do not go faster than 2.66 Ghz (maybe turboboost can make them reach 3.0 Ghz, I am not sure).