[llvm] r249241 - Move registerSection out of line and reduce #includes. NFC.
Rafael Espindola via llvm-commits
llvm-commits at lists.llvm.org
Sat Oct 3 11:28:40 PDT 2015
Author: rafael
Date: Sat Oct 3 13:28:40 2015
New Revision: 249241
URL: http://llvm.org/viewvc/llvm-project?rev=249241&view=rev
Log:
Move registerSection out of line and reduce #includes. NFC.
Modified:
llvm/trunk/include/llvm/MC/MCAssembler.h
llvm/trunk/lib/MC/MCAssembler.cpp
Modified: llvm/trunk/include/llvm/MC/MCAssembler.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/MC/MCAssembler.h?rev=249241&r1=249240&r2=249241&view=diff
==============================================================================
--- llvm/trunk/include/llvm/MC/MCAssembler.h (original)
+++ llvm/trunk/include/llvm/MC/MCAssembler.h Sat Oct 3 13:28:40 2015
@@ -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);
Modified: llvm/trunk/lib/MC/MCAssembler.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/MC/MCAssembler.cpp?rev=249241&r1=249240&r2=249241&view=diff
==============================================================================
--- llvm/trunk/lib/MC/MCAssembler.cpp (original)
+++ llvm/trunk/lib/MC/MCAssembler.cpp Sat Oct 3 13:28:40 2015
@@ -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;
More information about the llvm-commits
mailing list