mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2025-02-02 10:51:06 +00:00
target-i386: Generate fences for x86
Backports commit cc19e497a047193db5083425957d7292c8dd3226 from qemu
This commit is contained in:
parent
32b7cee81e
commit
533e083495
|
@ -8724,6 +8724,7 @@ case 0x101:
|
||||||
|| (prefixes & PREFIX_LOCK)) {
|
|| (prefixes & PREFIX_LOCK)) {
|
||||||
goto illegal_op;
|
goto illegal_op;
|
||||||
}
|
}
|
||||||
|
tcg_gen_mb(tcg_ctx, TCG_MO_ST_ST | TCG_BAR_SC);
|
||||||
break;
|
break;
|
||||||
case 0xe8:
|
case 0xe8:
|
||||||
case 0xe9:
|
case 0xe9:
|
||||||
|
@ -8733,6 +8734,12 @@ case 0x101:
|
||||||
case 0xed:
|
case 0xed:
|
||||||
case 0xee:
|
case 0xee:
|
||||||
case 0xef: /* lfence */
|
case 0xef: /* lfence */
|
||||||
|
if (!(s->cpuid_features & CPUID_SSE)
|
||||||
|
|| (prefixes & PREFIX_LOCK)) {
|
||||||
|
goto illegal_op;
|
||||||
|
}
|
||||||
|
tcg_gen_mb(tcg_ctx, TCG_MO_LD_LD | TCG_BAR_SC);
|
||||||
|
break;
|
||||||
case 0xf0:
|
case 0xf0:
|
||||||
case 0xf1:
|
case 0xf1:
|
||||||
case 0xf2:
|
case 0xf2:
|
||||||
|
@ -8745,6 +8752,7 @@ case 0x101:
|
||||||
|| (prefixes & PREFIX_LOCK)) {
|
|| (prefixes & PREFIX_LOCK)) {
|
||||||
goto illegal_op;
|
goto illegal_op;
|
||||||
}
|
}
|
||||||
|
tcg_gen_mb(tcg_ctx, TCG_MO_ALL | TCG_BAR_SC);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
Loading…
Reference in a new issue