[lld] r287372 - Simplify. NFC.
Rui Ueyama via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 18 11:45:05 PST 2016
Author: ruiu
Date: Fri Nov 18 13:45:04 2016
New Revision: 287372
URL: http://llvm.org/viewvc/llvm-project?rev=287372&view=rev
Log:
Simplify. NFC.
Modified:
lld/trunk/ELF/OutputSections.cpp
Modified: lld/trunk/ELF/OutputSections.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/OutputSections.cpp?rev=287372&r1=287371&r2=287372&view=diff
==============================================================================
--- lld/trunk/ELF/OutputSections.cpp (original)
+++ lld/trunk/ELF/OutputSections.cpp Fri Nov 18 13:45:04 2016
@@ -604,15 +604,11 @@ template <class ELFT> void MergeOutputSe
// finalize() fixed tail-optimized strings, so we can now get
// offsets of strings. Get an offset for each string and save it
// to a corresponding StringPiece for easy access.
- if (shouldTailMerge()) {
- for (MergeInputSection<ELFT> *Sec : Sections) {
- for (size_t I = 0, E = Sec->Pieces.size(); I != E; ++I) {
- if (!Sec->Pieces[I].Live)
- continue;
- Sec->Pieces[I].OutputOff = Builder.getOffset(Sec->getData(I));
- }
- }
- }
+ if (shouldTailMerge())
+ for (MergeInputSection<ELFT> *Sec : Sections)
+ for (size_t I = 0, E = Sec->Pieces.size(); I != E; ++I)
+ if (Sec->Pieces[I].Live)
+ Sec->Pieces[I].OutputOff = Builder.getOffset(Sec->getData(I));
}
template <class ELFT>
More information about the llvm-commits
mailing list