[clang] [HIP] use offload wrapper for non-device-only non-rdc (PR #132869)

Joseph Huber via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 28 10:59:57 PDT 2025


================
@@ -9332,11 +9332,22 @@ void LinkerWrapper::ConstructJob(Compilation &C, const JobAction &JA,
   // Add the linker arguments to be forwarded by the wrapper.
   CmdArgs.push_back(Args.MakeArgString(Twine("--linker-path=") +
                                        LinkCommand->getExecutable()));
-  for (const char *LinkArg : LinkCommand->getArguments())
-    CmdArgs.push_back(LinkArg);
 
-  addOffloadCompressArgs(Args, CmdArgs);
+  // We use action type to differentiate two use cases of the linker wrapper.
+  // TY_Image for normal linker wrapper work.
----------------
jhuber6 wrote:

It seems weird that this is getting `TY_Image`. I don't remember why that's the case. The linker wrapper is supposed to act like the linker, so why isn't it getting objects?

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


More information about the cfe-commits mailing list