Fix in rvfi_mem_ handling (when compressed isa is enabled)

This commit is contained in:
Clifford Wolf 2017-02-27 14:21:42 +01:00
parent aaa9e25756
commit f33ddd3654
1 changed files with 12 additions and 13 deletions

View File

@ -1906,20 +1906,19 @@ module picorv32 #(
rvfi_rd_wdata <= 0; rvfi_rd_wdata <= 0;
end end
if (dbg_mem_instr) begin
rvfi_mem_addr <= 0;
rvfi_mem_rmask <= 0;
rvfi_mem_wmask <= 0;
rvfi_mem_rdata <= 0;
rvfi_mem_wdata <= 0;
end else
if (dbg_mem_valid && dbg_mem_ready) begin if (dbg_mem_valid && dbg_mem_ready) begin
if (dbg_mem_instr) begin rvfi_mem_addr <= dbg_mem_addr;
rvfi_mem_addr <= 0; rvfi_mem_rmask <= dbg_mem_wstrb ? 0 : ~0;
rvfi_mem_rmask <= 0; rvfi_mem_wmask <= dbg_mem_wstrb;
rvfi_mem_wmask <= 0; rvfi_mem_rdata <= dbg_mem_rdata;
rvfi_mem_rdata <= 0; rvfi_mem_wdata <= dbg_mem_wdata;
rvfi_mem_wdata <= 0;
end else begin
rvfi_mem_addr <= dbg_mem_addr;
rvfi_mem_rmask <= dbg_mem_wstrb ? 0 : ~0;
rvfi_mem_wmask <= dbg_mem_wstrb;
rvfi_mem_rdata <= dbg_mem_rdata;
rvfi_mem_wdata <= dbg_mem_wdata;
end
end end
end end