summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MachObjectWriter.cpp
diff options
context:
space:
mode:
authorDavid Majnemer <david.majnemer@gmail.com>2014-03-07 07:36:05 +0000
committerDavid Majnemer <david.majnemer@gmail.com>2014-03-07 07:36:05 +0000
commit7b58305ff6f0e01f5c5bc75d98eacfb007ef2b88 (patch)
treec882a5d93ff21777f9e219f0b1dec13c079fe312 /llvm/lib/MC/MachObjectWriter.cpp
parent198c1685186e3798d8060a789534b61e1b34b064 (diff)
downloadbcm5719-llvm-7b58305ff6f0e01f5c5bc75d98eacfb007ef2b88.tar.gz
bcm5719-llvm-7b58305ff6f0e01f5c5bc75d98eacfb007ef2b88.zip
MC: Remove superfluous section attribute flag definitions
Summary: llvm/MC/MCSectionMachO.h and llvm/Support/MachO.h both had the same definitions for the section flags. Instead, grab the definitions out of support. No functionality change. Reviewers: grosbach, Bigcheese, rafael Reviewed By: rafael CC: llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D2998 llvm-svn: 203211
Diffstat (limited to 'llvm/lib/MC/MachObjectWriter.cpp')
-rw-r--r--llvm/lib/MC/MachObjectWriter.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/llvm/lib/MC/MachObjectWriter.cpp b/llvm/lib/MC/MachObjectWriter.cpp
index 4143d783e29..00347f546fc 100644
--- a/llvm/lib/MC/MachObjectWriter.cpp
+++ b/llvm/lib/MC/MachObjectWriter.cpp
@@ -229,7 +229,7 @@ void MachObjectWriter::WriteSection(const MCAssembler &Asm,
unsigned Flags = Section.getTypeAndAttributes();
if (SD.hasInstructions())
- Flags |= MCSectionMachO::S_ATTR_SOME_INSTRUCTIONS;
+ Flags |= MachO::S_ATTR_SOME_INSTRUCTIONS;
assert(isPowerOf2_32(SD.getAlignment()) && "Invalid alignment!");
Write32(Log2_32(SD.getAlignment()));
@@ -437,9 +437,9 @@ void MachObjectWriter::BindIndirectSymbols(MCAssembler &Asm) {
const MCSectionMachO &Section =
cast<MCSectionMachO>(it->SectionData->getSection());
- if (Section.getType() != MCSectionMachO::S_NON_LAZY_SYMBOL_POINTERS &&
- Section.getType() != MCSectionMachO::S_LAZY_SYMBOL_POINTERS &&
- Section.getType() != MCSectionMachO::S_SYMBOL_STUBS) {
+ if (Section.getType() != MachO::S_NON_LAZY_SYMBOL_POINTERS &&
+ Section.getType() != MachO::S_LAZY_SYMBOL_POINTERS &&
+ Section.getType() != MachO::S_SYMBOL_STUBS) {
MCSymbol &Symbol = *it->Symbol;
report_fatal_error("indirect symbol '" + Symbol.getName() +
"' not in a symbol pointer or stub section");
@@ -453,7 +453,7 @@ void MachObjectWriter::BindIndirectSymbols(MCAssembler &Asm) {
const MCSectionMachO &Section =
cast<MCSectionMachO>(it->SectionData->getSection());
- if (Section.getType() != MCSectionMachO::S_NON_LAZY_SYMBOL_POINTERS)
+ if (Section.getType() != MachO::S_NON_LAZY_SYMBOL_POINTERS)
continue;
// Initialize the section indirect symbol base, if necessary.
@@ -469,8 +469,8 @@ void MachObjectWriter::BindIndirectSymbols(MCAssembler &Asm) {
const MCSectionMachO &Section =
cast<MCSectionMachO>(it->SectionData->getSection());
- if (Section.getType() != MCSectionMachO::S_LAZY_SYMBOL_POINTERS &&
- Section.getType() != MCSectionMachO::S_SYMBOL_STUBS)
+ if (Section.getType() != MachO::S_LAZY_SYMBOL_POINTERS &&
+ Section.getType() != MachO::S_SYMBOL_STUBS)
continue;
// Initialize the section indirect symbol base, if necessary.
@@ -921,7 +921,7 @@ void MachObjectWriter::WriteObject(MCAssembler &Asm,
// special handling.
const MCSectionMachO &Section =
static_cast<const MCSectionMachO&>(it->SectionData->getSection());
- if (Section.getType() == MCSectionMachO::S_NON_LAZY_SYMBOL_POINTERS) {
+ if (Section.getType() == MachO::S_NON_LAZY_SYMBOL_POINTERS) {
// If this symbol is defined and internal, mark it as such.
if (it->Symbol->isDefined() &&
!Asm.getSymbolData(*it->Symbol).isExternal()) {
OpenPOWER on IntegriCloud