[lld] r265130 - Split Writer::assignAddresses(): extract assignPhdrs(). NFC.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 1 03:49:15 PDT 2016
Author: grimar
Date: Fri Apr 1 05:49:14 2016
New Revision: 265130
URL: http://llvm.org/viewvc/llvm-project?rev=265130&view=rev
Log:
Split Writer::assignAddresses(): extract assignPhdrs(). NFC.
Modified:
lld/trunk/ELF/Writer.cpp
Modified: lld/trunk/ELF/Writer.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Writer.cpp?rev=265130&r1=265129&r2=265130&view=diff
==============================================================================
--- lld/trunk/ELF/Writer.cpp (original)
+++ lld/trunk/ELF/Writer.cpp Fri Apr 1 05:49:14 2016
@@ -71,6 +71,7 @@ private:
void createPhdrs();
void assignAddresses();
void assignAddressesRelocatable();
+ void assignPhdrs();
void fixSectionAlignments();
void fixAbsoluteSymbols();
bool openFile();
@@ -1424,6 +1425,10 @@ template <class ELFT> void Writer<ELFT>:
SectionHeaderOff = alignTo(FileOff, sizeof(uintX_t));
FileSize = SectionHeaderOff + getNumSections() * sizeof(Elf_Shdr);
+ assignPhdrs();
+}
+
+template <class ELFT> void Writer<ELFT>::assignPhdrs() {
for (Phdr &PHdr : Phdrs) {
Elf_Phdr &H = PHdr.H;
if (PHdr.First) {
More information about the llvm-commits
mailing list