Move registerSection out of line and reduce #includes. NFC.

llvm-svn: 249241
This commit is contained in:
Rafael Espindola 2015-10-03 18:28:40 +00:00
parent 93ea954e6d
commit 28de224002
2 changed files with 9 additions and 8 deletions

View File

@ -22,7 +22,6 @@
#include "llvm/MC/MCFixup.h"
#include "llvm/MC/MCInst.h"
#include "llvm/MC/MCLinkerOptimizationHint.h"
#include "llvm/MC/MCSection.h"
#include "llvm/MC/MCSubtargetInfo.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/DataTypes.h"
@ -860,13 +859,7 @@ public:
/// \name Backend Data Access
/// @{
bool registerSection(MCSection &Section) {
if (Section.isRegistered())
return false;
Sections.push_back(&Section);
Section.setIsRegistered(true);
return true;
}
bool registerSection(MCSection &Section);
void registerSymbol(const MCSymbol &Symbol, bool *Created = nullptr);

View File

@ -357,6 +357,14 @@ void MCAssembler::reset() {
getLOHContainer().reset();
}
bool MCAssembler::registerSection(MCSection &Section) {
if (Section.isRegistered())
return false;
Sections.push_back(&Section);
Section.setIsRegistered(true);
return true;
}
bool MCAssembler::isThumbFunc(const MCSymbol *Symbol) const {
if (ThumbFuncs.count(Symbol))
return true;