Redo physical/logical CPU count.
Suggested by: jhb
This commit is contained in:
parent
1a330eb01d
commit
7c799f4520
@ -358,9 +358,10 @@ printcpuinfo(void)
|
||||
cmp = ((regs[0] & 0xfc000000) >> 26) + 1;
|
||||
}
|
||||
if (cmp > 1)
|
||||
printf("\n Physical cores: %d", cmp);
|
||||
if (htt > 1)
|
||||
printf("\n Logical cores: %d", htt);
|
||||
printf("\n Cores per package: %d", cmp);
|
||||
if ((htt / cmp) > 1)
|
||||
printf("\n Logical CPUs per core: %d",
|
||||
htt / cmp);
|
||||
}
|
||||
}
|
||||
/* Avoid ugly blank lines: only print newline when we have to. */
|
||||
|
@ -848,9 +848,10 @@ printcpuinfo(void)
|
||||
cmp = ((regs[0] & 0xfc000000) >> 26) + 1;
|
||||
}
|
||||
if (cmp > 1)
|
||||
printf("\n Physical cores: %d", cmp);
|
||||
if (htt > 1)
|
||||
printf("\n Logical cores: %d", htt);
|
||||
printf("\n Cores per package: %d", cmp);
|
||||
if ((htt / cmp) > 1)
|
||||
printf("\n Logical CPUs per core: %d",
|
||||
htt / cmp);
|
||||
}
|
||||
} else if (strcmp(cpu_vendor, "CyrixInstead") == 0) {
|
||||
printf(" DIR=0x%04x", cyrix_did);
|
||||
|
Loading…
x
Reference in New Issue
Block a user