kernel: add crash details on illegal instructions

This commit is contained in:
Lephe 2021-06-17 14:33:45 +02:00
parent 03ef59521c
commit 8d444b4f78
No known key found for this signature in database
GPG key ID: 1BBA026E13FC0495

View file

@ -117,7 +117,9 @@ GNORETURN static void gint_default_panic(GUNUSED uint32_t code)
/* Illegal instruction handler */
if(code == 0x180)
{
dprint(6, 141, "Opcode: %04x", *(uint16_t *)PC);
uint16_t *opcodes = (void *)PC;
dprint(6, 141, "Opcodes: %04x %04x [%04x] %04x",
opcodes[-2], opcodes[-1], opcodes[0], opcodes[1]);
}
#endif