prev_reg <= cur_reg;
prev_offset <= offset;
prev_raddr <= raddr;
- out_cpsr <= next_outcpsr;
- out_spsr <= spsr;
+ outcpsr <= next_outcpsr;
+ outspsr <= spsr;
swp_state <= next_swp_state;
+ lsm_state <= next_lsm_state;
+ lsr_state <= next_lsr_state;
+ lsrh_state <= next_lsrh_state;
+ prevaddr <= addr;
end
always @(*)
cp_rnw = 1'bx;
cp_write = 32'hxxxxxxxx;
offset = prev_offset;
- next_outcpsr = lsm_state == 3'b010 ? out_cpsr : cpsr;
+ next_outcpsr = lsm_state == 3'b010 ? outcpsr : cpsr;
+ lsrh_rddata = 32'hxxxxxxxx;
+ lsrh_rddata_s1 = 16'hxxxx;
+ lsrh_rddata_s2 = 8'hxx;
next_lsm_state = lsm_state;
next_lsr_state = lsr_state;
+ next_lsrh_state = lsrh_state;
next_swp_oldval = swp_oldval;
next_swp_state = swp_state;
cur_reg = prev_reg;
/* XXX shit not given about endianness */
- /* TODO ldrh/strh */
- casez(insn)
+ if (flush)
+ next_outbubble = 1'b1;
+ else casez(insn)
`DECODE_ALU_SWP: if(!inbubble) begin
outstall = rw_wait;
next_outbubble = rw_wait;