We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3e2a5ba commit 3d2cd67Copy full SHA for 3d2cd67
llvm/lib/Transforms/IPO/LowerTypeTests.cpp
@@ -361,6 +361,9 @@ struct ScopedSaveAliaseesAndUsed {
361
auto *GV = collectUsedGlobalVariables(M, Vec, CompilerUsed);
362
if (!GV)
363
return;
364
+ // There's no API to only remove certain array elements from
365
+ // llvm.used/llvm.compiler.used, so we remove all of them and add back only
366
+ // the non-functions.
367
GV->eraseFromParent();
368
auto NonFuncBegin =
369
std::stable_partition(Vec.begin(), Vec.end(), [](GlobalValue *GV) {
0 commit comments