mirror of
https://github.com/openhwgroup/cva6.git
synced 2025-04-24 22:27:10 -04:00
Report the last PC when debug not halted
This commit is contained in:
parent
a569aede23
commit
b3abf7491c
1 changed files with 3 additions and 4 deletions
|
@ -153,8 +153,6 @@ module debug_unit (
|
||||||
if (debug_halted_o) begin
|
if (debug_halted_o) begin
|
||||||
if (commit_instr_i.valid)
|
if (commit_instr_i.valid)
|
||||||
rdata_n = commit_instr_i.pc;
|
rdata_n = commit_instr_i.pc;
|
||||||
else
|
|
||||||
rdata_n = 64'hdeadbeefdeadbeef;
|
|
||||||
|
|
||||||
if (cause_is_bp_q)
|
if (cause_is_bp_q)
|
||||||
// if the cause is a breakpoint we trick the debugger in assuming the next instruction
|
// if the cause is a breakpoint we trick the debugger in assuming the next instruction
|
||||||
|
@ -163,8 +161,9 @@ module debug_unit (
|
||||||
rdata_n = dbg_ppc_q + 64'h2;
|
rdata_n = dbg_ppc_q + 64'h2;
|
||||||
else
|
else
|
||||||
rdata_n = dbg_ppc_q + 64'h4;
|
rdata_n = dbg_ppc_q + 64'h4;
|
||||||
// TODO: Breakpoint
|
// we are not in debug mode - so just report what we know: the last valid PC
|
||||||
end
|
end else
|
||||||
|
rdata_n = dbg_ppc_q;
|
||||||
// if we came from reset - output the boot address
|
// if we came from reset - output the boot address
|
||||||
if (reset_q)
|
if (reset_q)
|
||||||
rdata_n = boot_addr_i;
|
rdata_n = boot_addr_i;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue