================
@@ -9284,6 +9284,12 @@ void LinkerWrapper::ConstructJob(Compilation &C, const 
JobAction &JA,
         CmdArgs.push_back(Args.MakeArgString(
             "--device-linker=" + TC->getTripleString() + "=" + Arg));
 
+      // Enable internalization for AMDGPU.
+      if (TC->getTriple().isAMDGPU())
+        CmdArgs.push_back(
+            Args.MakeArgString("--device-linker=" + TC->getTripleString() +
+                               "=-plugin-opt=-amdgpu-internalize-symbols"));
----------------
shiltian wrote:

Not really a hack TBH, though we are the only target explicitly using it. It 
significantly affects our performance. The remaining uses of this pass are in 
(Thin)LTO, which has broader impact.

https://github.com/llvm/llvm-project/pull/138365
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to