summaryrefslogtreecommitdiff
path: root/src/core.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/core.rs')
-rw-r--r--src/core.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core.rs b/src/core.rs
index 27ccf3f..2596441 100644
--- a/src/core.rs
+++ b/src/core.rs
@@ -53,6 +53,11 @@ impl Core {
}
};
+ if instr == 0 {
+ eprintln!("Executing 0 instruction at {:X}", self.pc);
+ break;
+ }
+
assert_eq!(instr & 3, 3, "Compressed instructions not supported");
let instr = Instruction(instr);
@@ -73,7 +78,7 @@ impl Core {
}
}
} else {
- eprintln!("Invalid Instruction 0x{:08x} 0b{:032b}", instr.0, instr.0);
+ eprintln!("Invalid Instruction {:08x}", instr.0);
break;
}
}