mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2024-12-31 23:15:44 +00:00
regress: eflags_noset.c should only asm x86 code on x86 platform. fix #764
This commit is contained in:
parent
f4325f8c4e
commit
b12ce92468
|
@ -34,17 +34,20 @@ uint32_t realEflags()
|
||||||
"pushf\n\t"
|
"pushf\n\t"
|
||||||
"pop %0\n\t"
|
"pop %0\n\t"
|
||||||
"popf"
|
"popf"
|
||||||
#else
|
: "=r"(val)
|
||||||
|
: "r"(i)
|
||||||
|
: "%0");
|
||||||
|
#elif defined(__x86_64__)
|
||||||
__asm__("pushfq\n\t"
|
__asm__("pushfq\n\t"
|
||||||
"pushq %0\n\t"
|
"pushq %0\n\t"
|
||||||
"popfq\n\t"
|
"popfq\n\t"
|
||||||
"pushfq\n\t"
|
"pushfq\n\t"
|
||||||
"popq %0\n\t"
|
"popq %0\n\t"
|
||||||
"popfq"
|
"popfq"
|
||||||
#endif
|
|
||||||
: "=r"(val)
|
: "=r"(val)
|
||||||
: "r"(i)
|
: "r"(i)
|
||||||
: "%0");
|
: "%0");
|
||||||
|
#endif
|
||||||
|
|
||||||
printf("Real system eflags: 0x%08"PRIX3264"\n", val);
|
printf("Real system eflags: 0x%08"PRIX3264"\n", val);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue