瀏覽代碼

+ first batch of instructions added for Addi0Op2Op

florian 1 年之前
父節點
當前提交
42f15792ec
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      compiler/riscv/aoptcpurv.pas

+ 1 - 1
compiler/riscv/aoptcpurv.pas

@@ -332,7 +332,7 @@ implementation
          (taicpu(p).oper[2]^.typ=top_const) and
          (taicpu(p).oper[2]^.val=0) and
          GetNextInstructionUsingReg(p, hp1, taicpu(p).oper[0]^.reg) and
-         MatchInstruction(hp1, [A_SUB{$ifdef riscv64}{$endif}]) and
+         MatchInstruction(hp1, [A_SUB,A_ADD,A_SLL,A_SLT,A_AND,A_OR{$ifdef riscv64}{$endif}]) and
          (taicpu(hp1).ops=3) and
          (MatchOperand(taicpu(p).oper[0]^,taicpu(hp1).oper[2]^) or MatchOperand(taicpu(p).oper[0]^,taicpu(hp1).oper[1]^)) and
          (not RegModifiedBetween(taicpu(p).oper[1]^.reg, p,hp1)) and