[clang] 670438e - [OpenMP][Fix] Add offloading kind to AMDGPU libraries
Joseph Huber via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 14 18:18:45 PDT 2022
Author: Joseph Huber
Date: 2022-03-14T21:18:19-04:00
New Revision: 670438e55dc265dc0b25567e62a6e328d91f30a0
URL: https://github.com/llvm/llvm-project/commit/670438e55dc265dc0b25567e62a6e328d91f30a0
DIFF: https://github.com/llvm/llvm-project/commit/670438e55dc265dc0b25567e62a6e328d91f30a0.diff
LOG: [OpenMP][Fix] Add offloading kind to AMDGPU libraries
Summary:
A previous patch added the offloading kind to the triple format we used.
I forgot to update the line where we add the AMDGPU libraries.
Added:
Modified:
clang/lib/Driver/ToolChains/Clang.cpp
Removed:
################################################################################
diff --git a/clang/lib/Driver/ToolChains/Clang.cpp b/clang/lib/Driver/ToolChains/Clang.cpp
index 5c2b720b0872a..d942ec25f409c 100644
--- a/clang/lib/Driver/ToolChains/Clang.cpp
+++ b/clang/lib/Driver/ToolChains/Clang.cpp
@@ -8263,9 +8263,9 @@ void LinkerWrapper::ConstructJob(Compilation &C, const JobAction &JA,
RocmTC.getCommonDeviceLibNames(TCArgs, Arch.str());
for (StringRef LibName : BCLibs)
- CmdArgs.push_back(
- Args.MakeArgString("-target-library=" + TC->getTripleString() + "-" +
- Arch + "=" + LibName));
+ CmdArgs.push_back(Args.MakeArgString(
+ "-target-library=" + Action::GetOffloadKindName(Action::OFK_OpenMP) +
+ "-" + TC->getTripleString() + "-" + Arch + "=" + LibName));
}
if (D.isUsingLTO(/* IsOffload */ true)) {
More information about the cfe-commits
mailing list