chore: dump pipeline state on cpu panic

This commit is contained in:
Rekai Nyangadzayi Musuka 2022-08-26 21:45:35 -05:00
parent 11d170caa6
commit 092981794b
1 changed files with 2 additions and 0 deletions

View File

@ -538,6 +538,8 @@ pub const Arm7tdmi = struct {
std.debug.print("spsr: 0x{X:0>8} ", .{self.spsr.raw});
prettyPrintPsr(&self.spsr);
std.debug.print("pipeline: {??X:0>8}\n", .{self.pipe.stage});
if (self.cpsr.t.read()) {
const opcode = self.bus.dbgRead(u16, self.r[15] - 4);
const id = thumbIdx(opcode);