[llvm] [AMDGPU] Post-RA AGPR copy elimination pass (PR #153901)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 15 16:21:14 PDT 2025


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff HEAD~1 HEAD --extensions cpp,h -- llvm/lib/Target/AMDGPU/AMDGPUEliminateAGPRToVGPRCopy.cpp llvm/lib/Target/AMDGPU/AMDGPU.h llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUEliminateAGPRToVGPRCopy.cpp b/llvm/lib/Target/AMDGPU/AMDGPUEliminateAGPRToVGPRCopy.cpp
index 66e00e131..5dc1430ea 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUEliminateAGPRToVGPRCopy.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUEliminateAGPRToVGPRCopy.cpp
@@ -129,10 +129,11 @@ bool AMDGPUEliminateAGPRToVGPRCopyImpl::run(MachineFunction &MF) const {
               if (SIInstrInfo::isMFMA(UseMI)) {
                 if (&MO != TII.getNamedOperand(UseMI, AMDGPU::OpName::src0) &&
                     &MO != TII.getNamedOperand(UseMI, AMDGPU::OpName::src1)) {
-                  LLVM_DEBUG(dbgs() << "  Incompatible MFMA operand: " << UseMI);
+                  LLVM_DEBUG(dbgs()
+                             << "  Incompatible MFMA operand: " << UseMI);
                   return false;
                 }
-              } else if (!UseMI.isFullCopy()){
+              } else if (!UseMI.isFullCopy()) {
                 LLVM_DEBUG(dbgs() << "  Incompatible user: " << UseMI);
                 return false;
               }

``````````

</details>


https://github.com/llvm/llvm-project/pull/153901


More information about the llvm-commits mailing list