diff options
author | Akira Hatanaka <ahatanaka@apple.com> | 2015-10-15 00:11:03 +0000 |
---|---|---|
committer | Akira Hatanaka <ahatanaka@apple.com> | 2015-10-15 00:11:03 +0000 |
commit | 276332b47fc2f65feb46b762e2f0dfd3014ace35 (patch) | |
tree | f585f0fd00e07b14a24ea11b1edd61741d7575b4 /llvm/lib/MC/MCObjectFileInfo.cpp | |
parent | 89151a08fccfc088ec0aa49308129439ceb9942e (diff) | |
download | bcm5719-llvm-276332b47fc2f65feb46b762e2f0dfd3014ace35.tar.gz bcm5719-llvm-276332b47fc2f65feb46b762e2f0dfd3014ace35.zip |
Revert r250349.
Test case coal-sections-powerpc.s is still failing on some buildbots.
llvm-svn: 250351
Diffstat (limited to 'llvm/lib/MC/MCObjectFileInfo.cpp')
-rw-r--r-- | llvm/lib/MC/MCObjectFileInfo.cpp | 41 |
1 files changed, 13 insertions, 28 deletions
diff --git a/llvm/lib/MC/MCObjectFileInfo.cpp b/llvm/lib/MC/MCObjectFileInfo.cpp index 666a1c306c5..31091ef284a 100644 --- a/llvm/lib/MC/MCObjectFileInfo.cpp +++ b/llvm/lib/MC/MCObjectFileInfo.cpp @@ -114,37 +114,22 @@ void MCObjectFileInfo::initMachOMCObjectFileInfo(Triple T) { = Ctx->getMachOSection("__TEXT", "__const", 0, SectionKind::getReadOnly()); - // If the target is not powerpc, map the coal sections to the non-coal - // sections. - // - // "__TEXT/__textcoal_nt" => section "__TEXT/__text" - // "__TEXT/__const_coal" => section "__TEXT/__const" - // "__DATA/__datacoal_nt" => section "__DATA/__data" - Triple::ArchType ArchTy = T.getArch(); - - if (ArchTy == Triple::ppc || ArchTy == Triple::ppc64) { - TextCoalSection - = Ctx->getMachOSection("__TEXT", "__textcoal_nt", - MachO::S_COALESCED | - MachO::S_ATTR_PURE_INSTRUCTIONS, - SectionKind::getText()); - ConstTextCoalSection - = Ctx->getMachOSection("__TEXT", "__const_coal", - MachO::S_COALESCED, - SectionKind::getReadOnly()); - DataCoalSection - = Ctx->getMachOSection("__DATA","__datacoal_nt", - MachO::S_COALESCED, - SectionKind::getDataRel()); - } else { - TextCoalSection = TextSection; - ConstTextCoalSection = ReadOnlySection; - DataCoalSection = DataSection; - } - + TextCoalSection + = Ctx->getMachOSection("__TEXT", "__textcoal_nt", + MachO::S_COALESCED | + MachO::S_ATTR_PURE_INSTRUCTIONS, + SectionKind::getText()); + ConstTextCoalSection + = Ctx->getMachOSection("__TEXT", "__const_coal", + MachO::S_COALESCED, + SectionKind::getReadOnly()); ConstDataSection // .const_data = Ctx->getMachOSection("__DATA", "__const", 0, SectionKind::getReadOnlyWithRel()); + DataCoalSection + = Ctx->getMachOSection("__DATA","__datacoal_nt", + MachO::S_COALESCED, + SectionKind::getDataRel()); DataCommonSection = Ctx->getMachOSection("__DATA","__common", MachO::S_ZEROFILL, |