diff options
Diffstat (limited to 'lld/ELF/Writer.cpp')
-rw-r--r-- | lld/ELF/Writer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp index 3ef7bcdaa28..214b6d234ee 100644 --- a/lld/ELF/Writer.cpp +++ b/lld/ELF/Writer.cpp @@ -1022,7 +1022,7 @@ template <class ELFT> void Writer<ELFT>::fixSectionAlignments() { // sections. These are special, we do not include them into output sections // list, but have them to simplify the code. template <class ELFT> void Writer<ELFT>::fixHeaders() { - uintX_t BaseVA = ScriptConfig->DoLayout ? 0 : Config->VAStart; + uintX_t BaseVA = ScriptConfig->DoLayout ? 0 : Config->ImageBase; Out<ELFT>::ElfHeader->setVA(BaseVA); uintX_t Off = Out<ELFT>::ElfHeader->getSize(); Out<ELFT>::ProgramHeaders->setVA(Off + BaseVA); @@ -1030,7 +1030,7 @@ template <class ELFT> void Writer<ELFT>::fixHeaders() { // Assign VAs (addresses at run-time) to output sections. template <class ELFT> void Writer<ELFT>::assignAddresses() { - uintX_t VA = Config->VAStart + Out<ELFT>::ElfHeader->getSize() + + uintX_t VA = Config->ImageBase + Out<ELFT>::ElfHeader->getSize() + Out<ELFT>::ProgramHeaders->getSize(); uintX_t ThreadBssOffset = 0; |