mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-21 18:24:23 +00:00
Add the private linkage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62279 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -245,7 +245,7 @@ static bool fold(std::vector<Function *> &FnVec, unsigned i, unsigned j) {
|
||||
Function *G = FnVec[j];
|
||||
|
||||
if (!F->mayBeOverridden()) {
|
||||
if (G->hasInternalLinkage()) {
|
||||
if (G->hasLocalLinkage()) {
|
||||
F->setAlignment(std::max(F->getAlignment(), G->getAlignment()));
|
||||
G->replaceAllUsesWith(F);
|
||||
G->eraseFromParent();
|
||||
@ -329,7 +329,7 @@ bool MergeFunctions::runOnModule(Module &M) {
|
||||
if (F->isDeclaration() || F->isIntrinsic())
|
||||
continue;
|
||||
|
||||
if (!F->hasInternalLinkage() && !F->hasExternalLinkage() &&
|
||||
if (!F->hasLocalLinkage() && !F->hasExternalLinkage() &&
|
||||
!F->hasWeakLinkage())
|
||||
continue;
|
||||
|
||||
|
Reference in New Issue
Block a user