Home | History | Annotate | Download | only in MC
      1 //===- lib/MC/MCSection.cpp - Machine Code Section Representation ---------===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is distributed under the University of Illinois Open Source
      6 // License. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 
     10 #include "llvm/MC/MCSection.h"
     11 #include "llvm/MC/MCAsmInfo.h"
     12 #include "llvm/MC/MCContext.h"
     13 #include "llvm/MC/MCSymbol.h"
     14 #include "llvm/Support/raw_ostream.h"
     15 using namespace llvm;
     16 
     17 //===----------------------------------------------------------------------===//
     18 // MCSection
     19 //===----------------------------------------------------------------------===//
     20 
     21 MCSymbol *MCSection::getEndSymbol(MCContext &Ctx) const {
     22   if (!End)
     23     End = Ctx.createTempSymbol("sec_end", true);
     24   return End;
     25 }
     26 
     27 bool MCSection::hasEnded() const { return End && End->isInSection(); }
     28 
     29 MCSection::~MCSection() {
     30 }
     31 
     32