Improve exception dumps and general debug info, make the emulator capable of running the riscv ISA tests, and perform some general fixes i found while making it pass the tests for RV64I

This commit is contained in:
2025-12-30 20:18:23 +01:00
parent 6a0e5e63c1
commit 5a383956c9
6 changed files with 36 additions and 7 deletions

View File

@@ -6,9 +6,15 @@
const MASK_REGISTER: u32 = 0x1f;
#[derive(Debug, Clone, Copy)]
#[derive(Clone, Copy)]
pub struct Instruction(pub u32);
impl std::fmt::Debug for Instruction {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
f.write_fmt(format_args!("{:08x}", self.0))
}
}
#[allow(dead_code)]
impl Instruction {
#[inline]