This patch adds emulation for instructions protected by User-Mode Instruction Prevention (currently only implemented by Ryzen 3000 CPUs). I'm still working on tests but wanted to get some feedback, especially on these topics:
- I'm currently adding the exception handler in signal_init_process() but this doesn't feel like the right place to do it. Is there a better place for this to go?
- the instruction emulation helper functions are copied from ntoskrnl.exe/instr.c, would it be better to move them somewhere so they can be shared?
Brendan Shanks (1): ntdll: Add emulation for UMIP instructions
dlls/ntdll/Makefile.in | 1 + dlls/ntdll/signal_i386.c | 2 + dlls/ntdll/signal_x86_64.c | 3 + dlls/ntdll/umip.c | 787 +++++++++++++++++++++++++++++++++++++ dlls/ntdll/umip.h | 21 + 5 files changed, 814 insertions(+) create mode 100644 dlls/ntdll/umip.c create mode 100644 dlls/ntdll/umip.h