Changeset 50038 in vbox for trunk/src/VBox/VMM
- Timestamp:
- Jan 9, 2014 3:14:58 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR3/CPUM.cpp
r49977 r50038 1169 1169 1170 1170 1171 PCPUMCPUIDLEAF pStdLeaf0 = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 0, 0);1172 AssertLogRelReturn(pStdLeaf0, VERR_CPUM_IPE_2);1173 1174 1175 1171 /* Cpuid 1: 1176 1172 * Only report features we can support. … … 1179 1175 * options may require adjusting (i.e. stripping what was enabled). 1180 1176 */ 1181 PCPUMCPUIDLEAF pStdFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1, 0); 1177 PCPUMCPUIDLEAF pStdFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1178 1, 0); /* Note! Must refetch when used later. */ 1182 1179 AssertLogRelReturn(pStdFeatureLeaf, VERR_CPUM_IPE_2); 1183 1180 pStdFeatureLeaf->uEdx &= X86_CPUID_FEATURE_EDX_FPU … … 1280 1277 */ 1281 1278 PCPUMCPUIDLEAF pExtFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1282 UINT32_C(0x80000001), 0); 1279 UINT32_C(0x80000001), 0); /* Note! Must refetch when used later. */ 1283 1280 if (pExtFeatureLeaf) 1284 1281 { … … 1403 1400 */ 1404 1401 pCurLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 3, 0); 1402 pStdFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1, 0); 1405 1403 if ( !(pStdFeatureLeaf->uEdx & X86_CPUID_FEATURE_EDX_PSN) 1406 1404 && pCurLeaf) … … 1459 1457 if (pCurLeaf) 1460 1458 { 1459 pStdFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1, 0); 1461 1460 if (!(pStdFeatureLeaf->uEcx & X86_CPUID_FEATURE_ECX_MONITOR)) 1462 1461 pCurLeaf->uEax = pCurLeaf->uEbx = 0; … … 1558 1557 /* Legacy method to determine the number of cores. */ 1559 1558 pCurLeaf->uEcx |= (pVM->cCpus - 1); /* NC: Number of CPU cores - 1; 8 bits */ 1559 pExtFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1560 UINT32_C(0x80000001), 0); 1560 1561 if (pExtFeatureLeaf) 1561 1562 pExtFeatureLeaf->uEcx |= X86_CPUID_AMD_FEATURE_ECX_CMPL; … … 1658 1659 if (pCPUM->GuestFeatures.enmCpuVendor == CPUMCPUVENDOR_INTEL) 1659 1660 { 1661 pStdFeatureLeaf = cpumR3CpuIdGetLeaf(pCPUM->GuestInfo.paCpuIdLeavesR3, pCPUM->GuestInfo.cCpuIdLeaves, 1, 0); 1660 1662 uint32_t uCurIntelFamilyModelStep = RT_MAKE_U32_FROM_U8(ASMGetCpuStepping(pStdFeatureLeaf->uEax), 1661 1663 ASMGetCpuModelIntel(pStdFeatureLeaf->uEax),
Note:
See TracChangeset
for help on using the changeset viewer.