In the TD pass, don't iterate over the scalar map to find the globals, iterate over
[oota-llvm.git] / lib / Analysis / DataStructure / Printer.cpp
index ae528aeb345ec393d617cdb350f85809c5f53229..7cea561c1480041a051da12d779c33534fb2d3ca 100644 (file)
@@ -29,6 +29,7 @@ using namespace llvm;
 //
 namespace {
   cl::opt<bool> OnlyPrintMain("only-print-main-ds", cl::ReallyHidden);
+  cl::opt<bool> DontPrintAnything("dont-print-ds", cl::ReallyHidden);
   Statistic<> MaxGraphSize   ("dsnode", "Maximum graph size");
   Statistic<> NumFoldedNodes ("dsnode", "Number of folded nodes (in final graph)");
 }
@@ -272,14 +273,23 @@ static void printCollection(const Collection &C, std::ostream &O,
 
 // print - Print out the analysis results...
 void LocalDataStructures::print(std::ostream &O, const Module *M) const {
+  if (DontPrintAnything) return;
   printCollection(*this, O, M, "ds.");
 }
 
 void BUDataStructures::print(std::ostream &O, const Module *M) const {
+  if (DontPrintAnything) return;
   printCollection(*this, O, M, "bu.");
 }
 
 void TDDataStructures::print(std::ostream &O, const Module *M) const {
+  if (DontPrintAnything) return;
   printCollection(*this, O, M, "td.");
 }
 
+void CompleteBUDataStructures::print(std::ostream &O, const Module *M) const {
+  if (DontPrintAnything) return;
+  printCollection(*this, O, M, "cbu.");
+}
+
+