mirror of
https://github.com/wiiu-env/wut.git
synced 2025-02-02 20:32:34 +01:00
whb: Exception handler now works
* The context structure for the crash handler thread needs to be aligned to at least 8 bytes. * In my cases, the entry at the bottom of my stack always has a back-chain value of 0x1. Of course, this address is not likely to be part of the stack, so this should be considered to be the end of the stack. * During ISI exceptions, only a stack trace is printed, and during DSI, disassembly and stack information is printed. For some unknown reason, I never see register dumps.
This commit is contained in:
parent
d0f43d24b7
commit
eb1a610f92
@ -40,7 +40,7 @@ sRegistersLength = 0;
|
||||
static uint8_t
|
||||
sCrashThreadStack[THREAD_STACK_SIZE];
|
||||
|
||||
static OSThread
|
||||
static OSThread __attribute__((aligned(8)))
|
||||
sCrashThread;
|
||||
|
||||
static int
|
||||
@ -96,7 +96,7 @@ getStackTrace(OSContext *context)
|
||||
for (i = 0; i < 16; ++i) {
|
||||
uint32_t addr;
|
||||
|
||||
if (!stackPtr || (uintptr_t)stackPtr == 0xFFFFFFFF) {
|
||||
if (!stackPtr || (uintptr_t)stackPtr == 0x1 || (uintptr_t)stackPtr == 0xFFFFFFFF) {
|
||||
break;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user