mirror of
https://github.com/starr-dusT/yuzu-mainline
synced 2024-03-05 21:12:25 -08:00
x64: Add detection of monitorx instructions
monitorx introduces 2 instructions: MONITORX and MWAITX.
This commit is contained in:
parent
0fe44071f8
commit
4303ed614d
@ -93,6 +93,7 @@ void AppendCPUInfo(FieldCollection& fc) {
|
|||||||
add_field("CPU_Extension_x64_GFNI", caps.gfni);
|
add_field("CPU_Extension_x64_GFNI", caps.gfni);
|
||||||
add_field("CPU_Extension_x64_INVARIANT_TSC", caps.invariant_tsc);
|
add_field("CPU_Extension_x64_INVARIANT_TSC", caps.invariant_tsc);
|
||||||
add_field("CPU_Extension_x64_LZCNT", caps.lzcnt);
|
add_field("CPU_Extension_x64_LZCNT", caps.lzcnt);
|
||||||
|
add_field("CPU_Extension_x64_MONITORX", caps.monitorx);
|
||||||
add_field("CPU_Extension_x64_MOVBE", caps.movbe);
|
add_field("CPU_Extension_x64_MOVBE", caps.movbe);
|
||||||
add_field("CPU_Extension_x64_PCLMULQDQ", caps.pclmulqdq);
|
add_field("CPU_Extension_x64_PCLMULQDQ", caps.pclmulqdq);
|
||||||
add_field("CPU_Extension_x64_POPCNT", caps.popcnt);
|
add_field("CPU_Extension_x64_POPCNT", caps.popcnt);
|
||||||
|
@ -168,6 +168,7 @@ static CPUCaps Detect() {
|
|||||||
__cpuid(cpu_id, 0x80000001);
|
__cpuid(cpu_id, 0x80000001);
|
||||||
caps.lzcnt = Common::Bit<5>(cpu_id[2]);
|
caps.lzcnt = Common::Bit<5>(cpu_id[2]);
|
||||||
caps.fma4 = Common::Bit<16>(cpu_id[2]);
|
caps.fma4 = Common::Bit<16>(cpu_id[2]);
|
||||||
|
caps.monitorx = Common::Bit<29>(cpu_id[2]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (max_ex_fn >= 0x80000007) {
|
if (max_ex_fn >= 0x80000007) {
|
||||||
|
@ -63,6 +63,7 @@ struct CPUCaps {
|
|||||||
bool gfni : 1;
|
bool gfni : 1;
|
||||||
bool invariant_tsc : 1;
|
bool invariant_tsc : 1;
|
||||||
bool lzcnt : 1;
|
bool lzcnt : 1;
|
||||||
|
bool monitorx : 1;
|
||||||
bool movbe : 1;
|
bool movbe : 1;
|
||||||
bool pclmulqdq : 1;
|
bool pclmulqdq : 1;
|
||||||
bool popcnt : 1;
|
bool popcnt : 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user