summaryrefslogtreecommitdiff
path: root/llvm/lib/Object/IRSymtab.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Object/IRSymtab.cpp')
-rw-r--r--llvm/lib/Object/IRSymtab.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Object/IRSymtab.cpp b/llvm/lib/Object/IRSymtab.cpp
index 494ec089d7bd..2579fa37935f 100644
--- a/llvm/lib/Object/IRSymtab.cpp
+++ b/llvm/lib/Object/IRSymtab.cpp
@@ -48,7 +48,7 @@ static cl::opt<bool> DisableBitcodeVersionUpgrade(
static const char *PreservedSymbols[] = {
// There are global variables, so put it here instead of in
- // RuntimeLibcalls.def.
+ // RuntimeLibcalls.td.
// TODO: Are there similar such variables?
"__ssp_canary_word",
"__stack_chk_guard",
@@ -218,9 +218,9 @@ static DenseSet<StringRef> buildPreservedSymbolsSet(const Triple &TT) {
std::end(PreservedSymbols));
// FIXME: Do we need to pass in ABI fields from TargetOptions?
RTLIB::RuntimeLibcallsInfo Libcalls(TT);
- for (const char *Name : Libcalls.getLibcallNames()) {
- if (Name)
- PreservedSymbolSet.insert(Name);
+ for (RTLIB::LibcallImpl Impl : Libcalls.getLibcallImpls()) {
+ if (Impl != RTLIB::Unsupported)
+ PreservedSymbolSet.insert(Libcalls.getLibcallImplName(Impl));
}
return PreservedSymbolSet;
}