From 4b55ec1dc4e7c477672276a6a312e71b69029ffb Mon Sep 17 00:00:00 2001 From: Khalil Estell Date: Thu, 29 Aug 2024 13:04:02 -0700 Subject: [PATCH] :bug: Fixed release build throw This is still a flawed and broken system. We need to fix this to make this runtime actually viable! --- src/arm_cortex/estell/exception.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/arm_cortex/estell/exception.cpp b/src/arm_cortex/estell/exception.cpp index 7d631bf..5c61744 100644 --- a/src/arm_cortex/estell/exception.cpp +++ b/src/arm_cortex/estell/exception.cpp @@ -14,7 +14,6 @@ #include #include -#include #include #include #include @@ -2054,8 +2053,10 @@ extern "C" #elif OPTIMIZATION_LEVEL == Release std::uint32_t const* stack_pointer = *exception_object.cpu.sp; exception_object.cpu.r3 = stack_pointer[0]; - exception_object.cpu.pc = stack_pointer[1]; - exception_object.cpu.sp = stack_pointer + 2; + exception_object.cpu.r4 = stack_pointer[1]; + exception_object.cpu.r5 = stack_pointer[2]; + exception_object.cpu.pc = stack_pointer[3]; + exception_object.cpu.sp = stack_pointer + 4; #elif OPTIMIZATION_LEVEL == RelWithDebInfo #error "Sorry Release mode unwinding is not supported yet."; #endif