From: Joshua Wise Date: Thu, 22 May 2008 01:16:20 +0000 (-0400) Subject: Fix ld (nn), sp, for real this time. X-Git-Url: http://git.joshuawise.com/fpgaboy.git/commitdiff_plain/15686607cb2c5c8b936a7dde56381cddf230b015?ds=sidebyside;hp=5c83453744afce2e0415f839e8274156b69df83e Fix ld (nn), sp, for real this time. --- diff --git a/core/insn_ld_nn_sp.v b/core/insn_ld_nn_sp.v index ade83fe..2d86046 100644 --- a/core/insn_ld_nn_sp.v +++ b/core/insn_ld_nn_sp.v @@ -12,7 +12,7 @@ `EXEC_READ(`_PC + 16'h0001) end 2: begin - `EXEC_WRITE(({tmp, rdata}), `_SPL) + `EXEC_WRITE(({rdata, tmp}), `_SPL) end 3: begin `EXEC_WRITE(({tmp, tmp2}), `_SPH) @@ -30,7 +30,7 @@ case (cycle) 0: begin end 1: tmp <= rdata; - 2: {tmp, tmp2} <= {tmp, rdata} + 1; + 2: {tmp, tmp2} <= {rdata, tmp} + 1; 3: begin end 4: begin end endcase