mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Generate correct stubs for weak-linked symbols
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17101 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
cfbf9faaa4
commit
fcf4a42cdf
@ -366,8 +366,9 @@ void PowerPCAsmPrinter::printOp(const MachineOperand &MO,
|
||||
return;
|
||||
}
|
||||
|
||||
// External global variables need a non-lazily-resolved stub
|
||||
if (GV->isExternal() && getTM().AddressTaken.count(GV)) {
|
||||
// External or weakly linked global variables need non-lazily-resolved stubs
|
||||
if ((GV->isExternal() || GV->hasWeakLinkage()) &&
|
||||
getTM().AddressTaken.count(GV)) {
|
||||
GVStubs.insert(Name);
|
||||
O << "L" << Name << "$non_lazy_ptr";
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user