Skip to content

Commit c86c2a2

Browse files
committed
[𝘀𝗽𝗿] initial version
Created using spr 1.3.6
1 parent 11d97b3 commit c86c2a2

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

llvm/lib/Transforms/IPO/LowerTypeTests.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2453,6 +2453,17 @@ bool LowerTypeTestsModule::lower() {
24532453
} else {
24542454
Alias->setName(AliasName);
24552455
}
2456+
2457+
if (auto *F = M.getFunction((AliasName + ".cfi").str())) {
2458+
// Function can be an alias. In such case we need definition of .cfi
2459+
// of aliasee.
2460+
if (auto *CfiAleasee = M.getFunction((Aliasee + ".cfi").str())) {
2461+
F->replaceAllUsesWith(CfiAleasee);
2462+
F->eraseFromParent();
2463+
} else {
2464+
F->setName(Aliasee + ".cfi");
2465+
}
2466+
}
24562467
}
24572468
}
24582469
}

0 commit comments

Comments
 (0)