From: Joshua Wise Date: Thu, 26 Feb 2009 01:51:48 +0000 (-0500) Subject: Memory: Fix bug in which swp_oldval does not get latched (oops!). Make align_rddata... X-Git-Url: http://git.joshuawise.com/firearm.git/commitdiff_plain/55c6199c2c85349b6ff16144ec9cbd770b0ee5f6?ds=inline Memory: Fix bug in which swp_oldval does not get latched (oops!). Make align_rddata not a latch. --- diff --git a/Memory.v b/Memory.v index 6b52989..63dfb9b 100644 --- a/Memory.v +++ b/Memory.v @@ -121,6 +121,7 @@ module Memory( lsrh_state <= next_lsrh_state; if (do_rd_data_latch) rd_data_latch <= rd_data; + swp_oldval <= next_swp_oldval; prevaddr <= addr; end @@ -692,6 +693,10 @@ module Memory( lsrh_rddata_s1 = 16'hxxxx; lsrh_rddata_s2 = 8'hxx; next_swp_oldval = swp_oldval; + + align_s1 = 32'hxxxxxxxx; + align_s2 = 32'hxxxxxxxx; + align_rddata = 32'hxxxxxxxx; /* XXX shit not given about endianness */ casez(insn)