Compute the ELF SectionKind from the flags.
authorRafael Espindola <rafael.espindola@gmail.com>
Thu, 29 Jan 2015 17:33:21 +0000 (17:33 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Thu, 29 Jan 2015 17:33:21 +0000 (17:33 +0000)
commitba31e27f0adb88edffeacd8c18fc760ce7e0a640
treed19de061f8fb47d45741a5f684d6291b7b5ec648
parent1610730faf589649b94d35dd88ac754b99d8afc4
Compute the ELF SectionKind from the flags.

Any code creating an MCSectionELF knows ELF and already provides the flags.

SectionKind is an abstraction used by common code that uses a plain
MCSection.

Use the flags to compute the SectionKind. This removes a lot of
guessing and boilerplate from the MCSectionELF construction.

llvm-svn: 227476
21 files changed:
llvm/include/llvm/MC/MCContext.h
llvm/include/llvm/MC/MCSectionELF.h
llvm/lib/CodeGen/AsmPrinter/ErlangGCPrinter.cpp
llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
llvm/lib/MC/ELFObjectWriter.cpp
llvm/lib/MC/MCAsmInfoELF.cpp
llvm/lib/MC/MCContext.cpp
llvm/lib/MC/MCELFStreamer.cpp
llvm/lib/MC/MCObjectFileInfo.cpp
llvm/lib/MC/MCParser/ELFAsmParser.cpp
llvm/lib/MC/MCSectionELF.cpp
llvm/lib/Target/ARM/ARMTargetObjectFile.cpp
llvm/lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp
llvm/lib/Target/Hexagon/HexagonTargetObjectFile.cpp
llvm/lib/Target/Mips/MCTargetDesc/MipsOptionRecord.cpp
llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
llvm/lib/Target/Mips/MipsAsmPrinter.cpp
llvm/lib/Target/Mips/MipsTargetObjectFile.cpp
llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
llvm/lib/Target/R600/AMDGPUAsmPrinter.cpp
llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp