------------------------
cpu: count=1:2:2 ...
------------------------
i use cpuid's leaf-4 to detect addressable cores, but always get '1'. Here is a part of code:
Code: Select all
"movl $4,%%eax\n\t"
"movl $0,%%ecx\n\t"
"cpuid\n\t"
"shr $26,%%eax\n\t"
"inc %%eax\n\t"
"movl %%eax,%5\n\t"
"end:nop"
:"=m"(xapic_support),"=m"(x2apic_support),"=m"(multi_thread_support),"=m"(cpuid_input_max),"=m"(addressable_logic_num),\
"=m"(addressable_core_num), "=m"(cpuid_family)