[PATCH] D86517: [RISC-V] Mark C_MV as a move instruction

Alexander Richardson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 25 03:46:01 PDT 2020


arichardson created this revision.
arichardson added reviewers: asb, jrtc27, luismarques.
Herald added subscribers: llvm-commits, apazos, sameer.abuasal, pzheng, s.egerton, lenary, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, shiva0217, kito-cheng, niosHD, sabuasal, simoncook, johnrusso, rbar, hiraditya.
Herald added a project: LLVM.
arichardson requested review of this revision.
Herald added a subscriber: MaskRay.

Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D86517

Files:
  llvm/lib/Target/RISCV/RISCVInstrInfoC.td


Index: llvm/lib/Target/RISCV/RISCVInstrInfoC.td
===================================================================
--- llvm/lib/Target/RISCV/RISCVInstrInfoC.td
+++ llvm/lib/Target/RISCV/RISCVInstrInfoC.td
@@ -519,7 +519,8 @@
   let rs2 = 0;
 }
 
-let hasSideEffects = 0, mayLoad = 0, mayStore = 0 in
+let hasSideEffects = 0, mayLoad = 0, mayStore = 0, isMoveReg = 1,
+    isAsCheapAsAMove = 1 in
 def C_MV : RVInst16CR<0b1000, 0b10, (outs GPRNoX0:$rs1), (ins GPRNoX0:$rs2),
                       "c.mv", "$rs1, $rs2">,
            Sched<[WriteIALU, ReadIALU]>;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86517.287615.patch
Type: text/x-patch
Size: 563 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200825/e4f01c46/attachment.bin>


More information about the llvm-commits mailing list