[clang] [llvm] [AMDGPU][LTO] Assume closed world after linking (PR #105845)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 23 08:30:57 PDT 2024


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 6e78aef646c22b7087cbf7939c8016f4f59614a1 8830b6f390039c9a952a86ea52e8fe9559900448 --extensions cpp -- llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp 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/AMDGPUAttributor.cpp b/llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp
index c78fc66e41..53ee3e42ee 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUAttributor.cpp
@@ -1066,7 +1066,8 @@ static bool runImpl(Module &M, AnalysisGetter &AG, TargetMachine &TM,
 
   Attributor A(Functions, InfoCache, AC);
 
-  LLVM_DEBUG(dbgs() << "Module " << M.getName() << " is " << (AC.IsClosedWorldModule ? "" : "not ")
+  LLVM_DEBUG(dbgs() << "Module " << M.getName() << " is "
+                    << (AC.IsClosedWorldModule ? "" : "not ")
                     << "assumed to be a closed world\n");
 
   for (Function &F : M) {
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp b/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
index a4898366a2..869afdcc62 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
@@ -761,7 +761,8 @@ void AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
         if (EnableLowerModuleLDS)
           PM.addPass(AMDGPULowerModuleLDSPass(*this));
         if (EnableAMDGPUAttributor && Level != OptimizationLevel::O0)
-          PM.addPass(AMDGPUAttributorPass(*this, AMDGPUAttributorOptions{true} ));
+          PM.addPass(
+              AMDGPUAttributorPass(*this, AMDGPUAttributorOptions{true}));
       });
 
   PB.registerRegClassFilterParsingCallback(

``````````

</details>


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


More information about the llvm-commits mailing list