Skip to content

Commit 9ce1baf

Browse files
Revert "IRGen: Use llvm.compiler.used instead of llvm.used on ELF"
This reverts commit 2bbea54.
1 parent 6cca6e5 commit 9ce1baf

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

lib/IRGen/GenDecl.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1030,15 +1030,6 @@ bool LinkInfo::isUsed(IRLinkage IRL) {
10301030
///
10311031
/// This value must have a definition by the time the module is finalized.
10321032
void IRGenModule::addUsedGlobal(llvm::GlobalValue *global) {
1033-
1034-
// As of reviews.llvm.org/D97448 "ELF: Create unique SHF_GNU_RETAIN sections
1035-
// for llvm.used global objects" LLVM creates separate sections for globals in
1036-
// llvm.used on ELF. Therefore we use llvm.compiler.used on ELF instead.
1037-
if (TargetInfo.OutputObjectFormat == llvm::Triple::ELF) {
1038-
addCompilerUsedGlobal(global);
1039-
return;
1040-
}
1041-
10421033
LLVMUsed.push_back(global);
10431034
}
10441035

0 commit comments

Comments
 (0)