diff --git a/src/x87_ops_misc.h b/src/x87_ops_misc.h index b2f7d32..bde89c7 100644 --- a/src/x87_ops_misc.h +++ b/src/x87_ops_misc.h @@ -781,6 +781,8 @@ static int FSTENV() { FP_ENTER(); if (fplog) pclog("FSTENV %08X:%08X\n", easeg, cpu_state.eaaddr); + cpu_state.npxs = (cpu_state.npxs & ~(7 << 11)) | ((cpu_state.TOP & 7) << 11); + switch ((cr0 & 1) | (cpu_state.op32 & 0x100)) { case 0x000: /*16-bit real mode*/