[PATCH] D100939: [ExpandPostRAPseudos] Don't add duplicate implicit operands

Jay Foad via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 21 03:53:15 PDT 2021


foad created this revision.
foad added reviewers: arsenm, rampitec, mkuper.
Herald added subscribers: kerbowa, hiraditya, tpr, nhaehnle, jvesely.
foad requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.

When lowering COPY to a target instruction and transferring the implicit
operands, don't add any duplicate implicit operands. This affects AMDGPU
where both the original COPY and the lowered instruction like
V_MOV_B32_e32 can have an implicit use of $exec.

This is mostly just a cosmetic issue, but it could conceivably have
caused missed optimizations in
SIInstrInfo::isReallyTriviallyReMaterializable where we rely on counting
the number of implicit operands.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D100939

Files:
  llvm/lib/CodeGen/ExpandPostRAPseudos.cpp
  llvm/test/CodeGen/AMDGPU/accvgpr-copy.mir
  llvm/test/CodeGen/AMDGPU/copy_phys_vgpr64.mir
  llvm/test/CodeGen/AMDGPU/transform-block-with-return-to-epilog.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100939.339170.patch
Type: text/x-patch
Size: 74239 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210421/fe8894cd/attachment-0001.bin>


More information about the llvm-commits mailing list