]> granicus.if.org Git - llvm/commitdiff
Move addInitialFrameState out of line and remove the MCDwarf.h include.
authorEric Christopher <echristo@gmail.com>
Fri, 12 Apr 2019 06:57:45 +0000 (06:57 +0000)
committerEric Christopher <echristo@gmail.com>
Fri, 12 Apr 2019 06:57:45 +0000 (06:57 +0000)
This removes 50 transitive dependencies for a modification of
MCDwarf.h in a build of llc for a single out of line function
and reduces the build overhead by 20% without impacting test
time of check-llvm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@358258 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/MC/MCAsmInfo.h
lib/MC/MCAsmInfo.cpp

index e861df5bb3dd939a3a567575971da9393dc2916b..9548674e70ce76113cf53001003a7120ac6a86ee 100644 (file)
 
 #include "llvm/ADT/StringRef.h"
 #include "llvm/MC/MCDirectives.h"
-#include "llvm/MC/MCDwarf.h"
 #include "llvm/MC/MCTargetOptions.h"
 #include <vector>
 
 namespace llvm {
 
 class MCContext;
+class MCCFIInstruction;
 class MCExpr;
 class MCSection;
 class MCStreamer;
@@ -597,9 +597,7 @@ public:
     return SupportsExtendedDwarfLocDirective;
   }
 
-  void addInitialFrameState(const MCCFIInstruction &Inst) {
-    InitialFrameState.push_back(Inst);
-  }
+  void addInitialFrameState(const MCCFIInstruction &Inst);
 
   const std::vector<MCCFIInstruction> &getInitialFrameState() const {
     return InitialFrameState;
index dd16945f7f2e6d92328656d531cc386485ffbf03..71e51e320f8bdd8a2a01532268834e3620633aa3 100644 (file)
@@ -70,6 +70,10 @@ MCAsmInfo::MCAsmInfo() {
 
 MCAsmInfo::~MCAsmInfo() = default;
 
+void MCAsmInfo::addInitialFrameState(const MCCFIInstruction &Inst) {
+  InitialFrameState.push_back(Inst);
+}
+
 bool MCAsmInfo::isSectionAtomizableBySymbols(const MCSection &Section) const {
   return false;
 }