Skip to content

Commit c9dc225

Browse files
committed
[fpv] Add asserts to check crash dump connectivity
1 parent eb82c0d commit c9dc225

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

rtl/ibex_top.sv

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1171,4 +1171,14 @@ module ibex_top import ibex_pkg::*; #(
11711171
// Dummy instructions may only write to register 0, which is a special register when dummy
11721172
// instructions are enabled.
11731173
`ASSERT(WaddrAZeroForDummyInstr, dummy_instr_wb && rf_we_wb |-> rf_waddr_wb == '0)
1174+
1175+
// Ensure the crash dump is connected to the correct internal signals
1176+
`ASSERT(CrashDumpCurrentPCConn, crash_dump_o.current_pc === u_ibex_core.pc_id)
1177+
`ASSERT(CrashDumpNextPCConn, crash_dump_o.next_pc === u_ibex_core.pc_if)
1178+
`ASSERT(CrashDumpLastDataAddrConn,
1179+
crash_dump_o.last_data_addr === u_ibex_core.load_store_unit_i.addr_last_q)
1180+
`ASSERT(CrashDumpExceptionPCConn,
1181+
crash_dump_o.exception_pc === u_ibex_core.cs_registers_i.mepc_q)
1182+
`ASSERT(CrashDumpExceptionAddrConn,
1183+
crash_dump_o.exception_addr === u_ibex_core.cs_registers_i.mtval_q)
11741184
endmodule

0 commit comments

Comments
 (0)