Skip to content

Commit

Permalink
[HIP] Do not include the CUID module hash with the new driver (#84332)
Browse files Browse the repository at this point in the history
Summary:
The new driver does not need this hash and it can lead to redefined
symbol errors when the CUID hash isn't set.
  • Loading branch information
jhuber6 authored Mar 7, 2024
1 parent d1fc59c commit 630289f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clang/lib/CodeGen/CodeGenModule.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -916,7 +916,7 @@ void CodeGenModule::Release() {
llvm::ConstantArray::get(ATy, UsedArray), "__clang_gpu_used_external");
addCompilerUsedGlobal(GV);
}
if (LangOpts.HIP) {
if (LangOpts.HIP && !getLangOpts().OffloadingNewDriver) {
// Emit a unique ID so that host and device binaries from the same
// compilation unit can be associated.
auto *GV = new llvm::GlobalVariable(
Expand Down

0 comments on commit 630289f

Please sign in to comment.