Remove DebugLoc::print(LLVMContext, raw_ostream), it was just
authorEric Christopher <echristo@gmail.com>
Thu, 26 Feb 2015 23:32:17 +0000 (23:32 +0000)
committerEric Christopher <echristo@gmail.com>
Thu, 26 Feb 2015 23:32:17 +0000 (23:32 +0000)
forwarding to the one that didn't take a context.

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

include/llvm/IR/DebugLoc.h
lib/CodeGen/MachineInstr.cpp
lib/Transforms/Vectorize/LoopVectorize.cpp

index 86e64417099d0e15b8d2753522f7c4f46779e5a0..3d0a250d4280787afc023abe27c65b55c6e13941 100644 (file)
@@ -103,7 +103,7 @@ namespace llvm {
     void dump(const LLVMContext &) const { dump(); }
     /// \brief prints source location /path/to/file.exe:line:col @[inlined at]
     void print(raw_ostream &OS) const;
-    void print(const LLVMContext &, raw_ostream &OS) const { print(OS); }
+    //    void print(const LLVMContext &, raw_ostream &OS) const { print(OS); }
   };
 
 } // end namespace llvm
index 981e4a3e03f9061701d809dcb0fb759c1d12071d..00b5650933280ed660a05d1f8dd8b842cbabf1a3 100644 (file)
@@ -1512,12 +1512,6 @@ void MachineInstr::dump() const {
 #endif
 }
 
-static void printDebugLoc(DebugLoc DL, const MachineFunction *MF,
-                         raw_ostream &CommentOS) {
-  const LLVMContext &Ctx = MF->getFunction()->getContext();
-  DL.print(Ctx, CommentOS);
-}
-
 void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM,
                          bool SkipOpers) const {
   // We can be a bit tidier if we know the TargetMachine and/or MachineFunction.
@@ -1738,7 +1732,7 @@ void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM,
       DebugLoc InlinedAtDL = DebugLoc::getFromDILocation(InlinedAt);
       if (!InlinedAtDL.isUnknown() && MF) {
         OS << " inlined @[ ";
-        printDebugLoc(InlinedAtDL, MF, OS);
+       InlinedAtDL.print(OS);
         OS << " ]";
       }
     }
@@ -1747,7 +1741,7 @@ void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM,
   } else if (!debugLoc.isUnknown() && MF) {
     if (!HaveSemi) OS << ";";
     OS << " dbg:";
-    printDebugLoc(debugLoc, MF, OS);
+    debugLoc.print(OS);
   }
 
   OS << '\n';
index 61423063f4611d23973b7bc9e11e035e417414f0..c1b2389d8b2082fd726e5d219b2d5381962e44c0 100644 (file)
@@ -488,7 +488,7 @@ static std::string getDebugLocString(const Loop *L) {
     raw_string_ostream OS(Result);
     const DebugLoc LoopDbgLoc = L->getStartLoc();
     if (!LoopDbgLoc.isUnknown())
-      LoopDbgLoc.print(L->getHeader()->getContext(), OS);
+      LoopDbgLoc.print(OS);
     else
       // Just print the module name.
       OS << L->getHeader()->getParent()->getParent()->getModuleIdentifier();