target-i386: Implement CPUID[0xB] (Extended Topology Enumeration)
commit5232d00a041c8f3628b3532ef35d703a1f0dac19
authorRadim Krčmář <rkrcmar@redhat.com>
Thu, 12 May 2016 17:24:26 +0000 (12 19:24 +0200)
committerEduardo Habkost <ehabkost@redhat.com>
Tue, 14 Jun 2016 19:17:08 +0000 (14 16:17 -0300)
treeb8be8c9cd1ce38409a68e73a36c44de101662392
parentd86c145114183f74114a27ecc8e2117a8b5d51aa
target-i386: Implement CPUID[0xB] (Extended Topology Enumeration)

I looked at a dozen Intel CPU that have this CPUID and all of them
always had Core offset as 1 (a wasted bit when hyperthreading is
disabled) and Package offset at least 4 (wasted bits at <= 4 cores).

QEMU uses more compact IDs and it doesn't make much sense to change it
now.  I keep the SMT and Core sub-leaves even if there is just one
thread/core;  it makes the code simpler and there should be no harm.

Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
include/hw/i386/pc.h
target-i386/cpu.c
target-i386/cpu.h