lst = ["addi 9, 0, 0x10", # i = 16
"addi 9,9,-1", # i = i - 1
"cmpi 2,1,9,12", # compare 9 to value 12, store in CR2
- "bc 4,10,-8", # branch if CR2 "test was != 12"
+ "bc 4,10,-16", # branch if CR2 "test was != 12"
'attn',
]
# address of the next instruction, in the absence of a branch
# depends on the instruction size
nia = Signal(64)
- with m.If(core_rst):
- sync += nia.eq(0)
# connect up debug signals
# TODO comb += core.icache_rst_i.eq(dbg.icache_rst_o)
exec_insn_valid_i, exec_insn_ready_o,
exec_pc_valid_o, exec_pc_ready_i)
+ # whatever was done above, over-ride it if core reset is held
+ with m.If(core_rst):
+ sync += nia.eq(0)
+
# this bit doesn't have to be in the FSM: connect up to read
# regfiles on demand from DMI
self.do_dmi(m, dbg)