decode1: Fix decoding of recommended NOP instruction
authorPaul Mackerras <paulus@ozlabs.org>
Thu, 26 Nov 2020 11:08:47 +0000 (22:08 +1100)
committerPaul Mackerras <paulus@ozlabs.org>
Fri, 15 Jan 2021 01:40:09 +0000 (12:40 +1100)
We were decoding nop with the wrong major opcode.  Fix it.

Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
decode1.vhdl

index 6624a53555f2261ff0a5904b862d99b80da6c14c..cfcf42452ba8ae5f897e04cd5dce940428f476e5 100644 (file)
@@ -633,10 +633,7 @@ begin
                 v.ispr2 := fast_spr_num(SPR_SRR0);
             end if;
 
-        when 30 =>
-            v.decode := decode_op_30_array(to_integer(unsigned(f_in.insn(4 downto 1))));
-
-        when 48 =>
+        when 24 =>
             -- ori, special-case the standard NOP
             if std_match(f_in.insn, "01100000000000000000000000000000") then
                 report "PPC_nop";
@@ -644,6 +641,9 @@ begin
                 vi.override_decode := nop_instr;
             end if;
 
+        when 30 =>
+            v.decode := decode_op_30_array(to_integer(unsigned(f_in.insn(4 downto 1))));
+
         when 58 =>
             v.decode := decode_op_58_array(to_integer(unsigned(f_in.insn(1 downto 0))));