From 09328b3ef8ec2977fc549dbbc120bb5def7854c1 Mon Sep 17 00:00:00 2001 From: George Rimar Date: Fri, 12 May 2017 17:00:07 +0000 Subject: [PATCH] [ELF] - Apply clang-format. NFC. llvm-svn: 302921 --- lld/ELF/Writer.cpp | 41 ++++++++++++++++++++++++++++------------- 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp index 4020fb1..9bfefff 100644 --- a/lld/ELF/Writer.cpp +++ b/lld/ELF/Writer.cpp @@ -164,11 +164,10 @@ static void combineMergableSections() { uint64_t Flags = MS->Flags & ~(uint64_t)(SHF_GROUP | SHF_COMPRESSED); uint32_t Alignment = std::max(MS->Alignment, MS->Entsize); - auto I = - llvm::find_if(MergeSections, [=](MergeSyntheticSection *Sec) { - return Sec->Name == OutsecName && Sec->Flags == Flags && - Sec->Alignment == Alignment; - }); + auto I = llvm::find_if(MergeSections, [=](MergeSyntheticSection *Sec) { + return Sec->Name == OutsecName && Sec->Flags == Flags && + Sec->Alignment == Alignment; + }); if (I == MergeSections.end()) { MergeSyntheticSection *Syn = make(OutsecName, MS->Type, Flags, Alignment); @@ -1204,14 +1203,30 @@ template void Writer::finalizeSections() { // Dynamic section must be the last one in this list and dynamic // symbol table section (DynSymTab) must be the first one. - applySynthetic({In::DynSymTab, InX::Bss, InX::BssRelRo, - In::GnuHashTab, In::HashTab, In::SymTab, - InX::ShStrTab, InX::StrTab, In::VerDef, - InX::DynStrTab, InX::GdbIndex, InX::Got, - InX::MipsGot, InX::IgotPlt, InX::GotPlt, - In::RelaDyn, In::RelaIplt, In::RelaPlt, - InX::Plt, InX::Iplt, In::EhFrameHdr, - In::VerSym, In::VerNeed, InX::Dynamic}, + applySynthetic({In::DynSymTab, + InX::Bss, + InX::BssRelRo, + In::GnuHashTab, + In::HashTab, + In::SymTab, + InX::ShStrTab, + InX::StrTab, + In::VerDef, + InX::DynStrTab, + InX::GdbIndex, + InX::Got, + InX::MipsGot, + InX::IgotPlt, + InX::GotPlt, + In::RelaDyn, + In::RelaIplt, + In::RelaPlt, + InX::Plt, + InX::Iplt, + In::EhFrameHdr, + In::VerSym, + In::VerNeed, + InX::Dynamic}, [](SyntheticSection *SS) { SS->finalizeContents(); }); // Some architectures use small displacements for jump instructions. -- 2.7.4