Add an assertion.
[oota-llvm.git] / lib / CodeGen / LiveInterval.cpp
index 8e3f888d00ed74a5a46d24d6f9bf52f0bec66320..0ca16007b2d4b6e20eb188cb8c4d0710c8483272 100644 (file)
 
 #include "llvm/CodeGen/LiveInterval.h"
 #include "llvm/ADT/STLExtras.h"
+#include "llvm/Support/Streams.h"
 #include "llvm/Target/MRegisterInfo.h"
 #include <algorithm>
-#include <iostream>
 #include <map>
+#include <ostream>
 using namespace llvm;
 
 // An example for liveAt():
@@ -466,13 +467,12 @@ void LiveInterval::MergeValueNumberInto(unsigned V1, unsigned V2) {
   }
 }
 
-
 std::ostream& llvm::operator<<(std::ostream& os, const LiveRange &LR) {
   return os << '[' << LR.start << ',' << LR.end << ':' << LR.ValId << ")";
 }
 
 void LiveRange::dump() const {
-  std::cerr << *this << "\n";
+  cerr << *this << "\n";
 }
 
 void LiveInterval::print(std::ostream &OS, const MRegisterInfo *MRI) const {
@@ -508,5 +508,10 @@ void LiveInterval::print(std::ostream &OS, const MRegisterInfo *MRI) const {
 }
 
 void LiveInterval::dump() const {
-  std::cerr << *this << "\n";
+  cerr << *this << "\n";
+}
+
+
+void LiveRange::print(std::ostream &os) const {
+  os << *this;
 }