From 85efb47a3b55b8a9991981ecd02520412d033f20 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Fri, 21 Aug 2026 13:16:43 +0200 Subject: [PATCH] Windows: Handle interrupt 3 in HandleGuestException --- Source/Windows/Common/Exception.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Source/Windows/Common/Exception.h b/Source/Windows/Common/Exception.h index b3a8518f8..a02f899b4 100644 --- a/Source/Windows/Common/Exception.h +++ b/Source/Windows/Common/Exception.h @@ -42,6 +42,13 @@ static inline EXCEPTION_RECORD HandleGuestException(FEXCore::Core::CpuStateFrame case FEXCore::X86State::X86_TRAPNO_GP: if ((Fault.err_code & 0b111) == 0b010) { switch (Fault.err_code >> 3) { + case 3: + Rip += 2; + Dst.ExceptionAddress = reinterpret_cast(Rip - 1); + Dst.ExceptionCode = EXCEPTION_BREAKPOINT; + Dst.NumberParameters = 1; + Dst.ExceptionInformation[0] = 0; + return Dst; case 0x29: Dst.ExceptionCode = STATUS_STACK_BUFFER_OVERRUN; Dst.ExceptionAddress = reinterpret_cast(Rip);