mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-03-24 07:35:04 +00:00
The value is offset from the start of the section for non-common symbols, submitted by Jordan Gordeev.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112473 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
679d236117
commit
51799ddc7c
@ -384,6 +384,8 @@ void ELFObjectWriterImpl::WriteSymbol(MCDataFragment *F, ELFSymbolData &MSD,
|
||||
}
|
||||
} else if (ESize->getKind() == MCExpr::Constant) {
|
||||
Size = static_cast<const MCConstantExpr *>(ESize)->getValue();
|
||||
MCFragment *F = Data.getFragment();
|
||||
Value = Layout.getSymbolAddress(&Data) - Layout.getSectionAddress(F->getParent());
|
||||
} else {
|
||||
assert(0 && "Unsupported size expression");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user