This patch adds emulation for instructions protected by User-Mode Instruction Prevention (currently implemented by AMD Ryzen 3000 CPUs and some rare Intel CPUs).
Changes from previous patch: - Fix calculation of RIP-relative addresses in INSTR_GetOperandAddr(), they are relative to the next instruction's RIP and not the current RIP. This was causing Ace Combat 7 to crash. - Call is_privileged_instr() before an exception stack frame is created. Wolfenstein: Youngblood calls sgdt with RSP not pointing to the stack, and the creation of the exception stack frame was overwriting data and causing a crash.
Brendan Shanks (2): ntdll: Add emulation for UMIP instructions. ntdll/tests: Add tests for UMIP instructions.
dlls/ntdll/signal_i386.c | 333 ++++++++++++++++++++++++++++++- dlls/ntdll/signal_x86_64.c | 374 +++++++++++++++++++++++++++++++++- dlls/ntdll/tests/exception.c | 375 +++++++++++++++++++++++++++++++++++ 3 files changed, 1066 insertions(+), 16 deletions(-)