[PATCH] D95586: [ARM] permit PC as destination of MOVS

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 8 16:44:08 PST 2021


nickdesaulniers added a comment.

  diff --git a/llvm/lib/Target/ARM/ARMInstrThumb2.td b/llvm/lib/Target/ARM/ARMInstrThumb2.td
  index 5642cab32e7c..d21fe9d04095 100644
  --- a/llvm/lib/Target/ARM/ARMInstrThumb2.td
  +++ b/llvm/lib/Target/ARM/ARMInstrThumb2.td
  @@ -4144,6 +4144,8 @@ def t2SUBS_PC_LR : T2I <(outs), (ins imm0_255:$imm), NoItinerary,
     bits<8> imm;
     let Inst{7-0} = imm;
   }
  +def : t2InstAlias<"movs{$p}\tpc, lr", (t2SUBS_PC_LR 0, pred:$p)>;
  +def : t2InstAlias<"movs{$p}.w\tpc, lr", (t2SUBS_PC_LR 0, pred:$p)>;
   
   // Hypervisor Call is a system instruction.
   let isCall = 1 in {

seems to work, will work on fixing the up tests more tomorrow


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D95586/new/

https://reviews.llvm.org/D95586



More information about the llvm-commits mailing list