2002-07-10 22:38:08 +00:00
|
|
|
//===- Printer.cpp - Code for printing data structure graphs nicely -------===//
|
2003-10-20 19:43:21 +00:00
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file was developed by the LLVM research group and is distributed under
|
|
|
|
// the University of Illinois Open Source License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
2002-07-10 22:38:08 +00:00
|
|
|
//
|
|
|
|
// This file implements the 'dot' graph printer.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2004-07-07 06:32:21 +00:00
|
|
|
#include "llvm/Analysis/DataStructure/DataStructure.h"
|
2005-03-13 19:51:24 +00:00
|
|
|
#include "llvm/Analysis/DataStructure/EquivClassGraphs.h"
|
2004-07-07 06:32:21 +00:00
|
|
|
#include "llvm/Analysis/DataStructure/DSGraph.h"
|
|
|
|
#include "llvm/Analysis/DataStructure/DSGraphTraits.h"
|
2002-07-10 22:38:08 +00:00
|
|
|
#include "llvm/Module.h"
|
2003-07-01 16:27:32 +00:00
|
|
|
#include "llvm/Constants.h"
|
2002-07-10 22:38:08 +00:00
|
|
|
#include "llvm/Assembly/Writer.h"
|
2004-09-01 22:55:40 +00:00
|
|
|
#include "llvm/Support/CommandLine.h"
|
|
|
|
#include "llvm/Support/GraphWriter.h"
|
|
|
|
#include "llvm/ADT/Statistic.h"
|
2002-07-10 22:38:08 +00:00
|
|
|
#include <fstream>
|
|
|
|
#include <sstream>
|
2003-11-12 23:11:14 +00:00
|
|
|
using namespace llvm;
|
2003-11-11 22:41:34 +00:00
|
|
|
|
2002-10-03 20:38:41 +00:00
|
|
|
// OnlyPrintMain - The DataStructure printer exposes this option to allow
|
|
|
|
// printing of only the graph for "main".
|
|
|
|
//
|
2002-11-18 21:42:45 +00:00
|
|
|
namespace {
|
|
|
|
cl::opt<bool> OnlyPrintMain("only-print-main-ds", cl::ReallyHidden);
|
2004-01-22 13:42:43 +00:00
|
|
|
cl::opt<bool> DontPrintAnything("dont-print-ds", cl::ReallyHidden);
|
2004-02-07 23:58:05 +00:00
|
|
|
Statistic<> MaxGraphSize ("dsa", "Maximum graph size");
|
|
|
|
Statistic<> NumFoldedNodes ("dsa", "Number of folded nodes (in final graph)");
|
2002-11-18 21:42:45 +00:00
|
|
|
}
|
2002-10-03 20:38:41 +00:00
|
|
|
|
2002-07-10 22:38:08 +00:00
|
|
|
void DSNode::dump() const { print(std::cerr, 0); }
|
|
|
|
|
2003-02-01 04:01:21 +00:00
|
|
|
static std::string getCaption(const DSNode *N, const DSGraph *G) {
|
2002-07-10 22:38:08 +00:00
|
|
|
std::stringstream OS;
|
2003-06-30 03:15:25 +00:00
|
|
|
Module *M = 0;
|
2004-02-25 23:06:30 +00:00
|
|
|
|
2004-03-02 21:39:43 +00:00
|
|
|
if (!G) G = N->getParentGraph();
|
2004-02-25 23:06:30 +00:00
|
|
|
|
2003-06-30 03:15:25 +00:00
|
|
|
// Get the module from ONE of the functions in the graph it is available.
|
2005-03-15 16:55:04 +00:00
|
|
|
if (G && G->retnodes_begin() != G->retnodes_end())
|
|
|
|
M = G->retnodes_begin()->first->getParent();
|
2004-03-02 21:39:43 +00:00
|
|
|
if (M == 0 && G) {
|
|
|
|
// If there is a global in the graph, we can use it to find the module.
|
|
|
|
const DSScalarMap &SM = G->getScalarMap();
|
|
|
|
if (SM.global_begin() != SM.global_end())
|
|
|
|
M = (*SM.global_begin())->getParent();
|
|
|
|
}
|
2002-10-01 22:33:50 +00:00
|
|
|
|
2002-11-06 06:20:27 +00:00
|
|
|
if (N->isNodeCompletelyFolded())
|
2003-07-02 04:39:27 +00:00
|
|
|
OS << "COLLAPSED";
|
2002-11-06 06:20:27 +00:00
|
|
|
else {
|
2002-11-18 21:42:45 +00:00
|
|
|
WriteTypeSymbolic(OS, N->getType(), M);
|
|
|
|
if (N->isArray())
|
2002-10-20 20:39:17 +00:00
|
|
|
OS << " array";
|
2002-11-06 06:20:27 +00:00
|
|
|
}
|
2003-06-19 21:15:11 +00:00
|
|
|
if (unsigned NodeType = N->getNodeFlags()) {
|
2002-11-06 06:20:27 +00:00
|
|
|
OS << ": ";
|
2003-06-19 21:15:11 +00:00
|
|
|
if (NodeType & DSNode::AllocaNode ) OS << "S";
|
|
|
|
if (NodeType & DSNode::HeapNode ) OS << "H";
|
|
|
|
if (NodeType & DSNode::GlobalNode ) OS << "G";
|
|
|
|
if (NodeType & DSNode::UnknownNode) OS << "U";
|
|
|
|
if (NodeType & DSNode::Incomplete ) OS << "I";
|
|
|
|
if (NodeType & DSNode::Modified ) OS << "M";
|
|
|
|
if (NodeType & DSNode::Read ) OS << "R";
|
|
|
|
#ifndef NDEBUG
|
|
|
|
if (NodeType & DSNode::DEAD ) OS << "<dead>";
|
|
|
|
#endif
|
2002-10-01 22:33:50 +00:00
|
|
|
OS << "\n";
|
|
|
|
}
|
|
|
|
|
|
|
|
for (unsigned i = 0, e = N->getGlobals().size(); i != e; ++i) {
|
|
|
|
WriteAsOperand(OS, N->getGlobals()[i], false, true, M);
|
2002-07-11 20:33:32 +00:00
|
|
|
OS << "\n";
|
|
|
|
}
|
|
|
|
|
2002-07-10 22:38:08 +00:00
|
|
|
return OS.str();
|
|
|
|
}
|
|
|
|
|
2003-11-12 23:11:14 +00:00
|
|
|
namespace llvm {
|
2002-10-13 19:31:57 +00:00
|
|
|
template<>
|
2002-10-17 01:02:46 +00:00
|
|
|
struct DOTGraphTraits<const DSGraph*> : public DefaultDOTGraphTraits {
|
|
|
|
static std::string getGraphName(const DSGraph *G) {
|
2003-06-30 03:15:25 +00:00
|
|
|
switch (G->getReturnNodes().size()) {
|
2003-06-30 05:57:39 +00:00
|
|
|
case 0: return G->getFunctionNames();
|
|
|
|
case 1: return "Function " + G->getFunctionNames();
|
|
|
|
default: return "Functions: " + G->getFunctionNames();
|
2003-06-30 03:15:25 +00:00
|
|
|
}
|
2002-10-13 19:31:57 +00:00
|
|
|
}
|
|
|
|
|
2002-10-17 01:02:46 +00:00
|
|
|
static std::string getNodeLabel(const DSNode *Node, const DSGraph *Graph) {
|
2002-10-13 19:31:57 +00:00
|
|
|
return getCaption(Node, Graph);
|
|
|
|
}
|
|
|
|
|
2002-10-17 01:02:46 +00:00
|
|
|
static std::string getNodeAttributes(const DSNode *N) {
|
2004-05-05 06:10:06 +00:00
|
|
|
return "shape=Mrecord";
|
2002-10-13 19:31:57 +00:00
|
|
|
}
|
2004-06-22 07:13:10 +00:00
|
|
|
|
|
|
|
static bool edgeTargetsEdgeSource(const void *Node,
|
|
|
|
DSNode::const_iterator I) {
|
|
|
|
unsigned O = I.getNode()->getLink(I.getOffset()).getOffset();
|
|
|
|
return (O >> DS::PointerShift) != 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
static DSNode::const_iterator getEdgeTarget(const DSNode *Node,
|
|
|
|
DSNode::const_iterator I) {
|
|
|
|
unsigned O = I.getNode()->getLink(I.getOffset()).getOffset();
|
|
|
|
unsigned LinkNo = O >> DS::PointerShift;
|
|
|
|
const DSNode *N = *I;
|
|
|
|
DSNode::const_iterator R = N->begin();
|
|
|
|
for (; LinkNo; --LinkNo)
|
|
|
|
++R;
|
|
|
|
return R;
|
|
|
|
}
|
|
|
|
|
2002-10-13 19:31:57 +00:00
|
|
|
|
2002-10-16 02:04:36 +00:00
|
|
|
/// addCustomGraphFeatures - Use this graph writing hook to emit call nodes
|
|
|
|
/// and the return node.
|
|
|
|
///
|
2002-10-17 01:02:46 +00:00
|
|
|
static void addCustomGraphFeatures(const DSGraph *G,
|
|
|
|
GraphWriter<const DSGraph*> &GW) {
|
2003-06-30 03:15:25 +00:00
|
|
|
Module *CurMod = 0;
|
2005-03-15 16:55:04 +00:00
|
|
|
if (G->retnodes_begin() != G->retnodes_end())
|
|
|
|
CurMod = G->retnodes_begin()->first->getParent();
|
2004-03-02 21:39:43 +00:00
|
|
|
else {
|
|
|
|
// If there is a global in the graph, we can use it to find the module.
|
|
|
|
const DSScalarMap &SM = G->getScalarMap();
|
|
|
|
if (SM.global_begin() != SM.global_end())
|
|
|
|
CurMod = (*SM.global_begin())->getParent();
|
|
|
|
}
|
|
|
|
|
2003-02-04 00:03:18 +00:00
|
|
|
|
2002-11-02 00:13:20 +00:00
|
|
|
// Add scalar nodes to the graph...
|
2003-06-30 03:15:25 +00:00
|
|
|
const DSGraph::ScalarMapTy &VM = G->getScalarMap();
|
|
|
|
for (DSGraph::ScalarMapTy::const_iterator I = VM.begin(); I != VM.end();++I)
|
2004-07-18 00:18:30 +00:00
|
|
|
if (!isa<GlobalValue>(I->first)) {
|
2002-11-02 00:13:20 +00:00
|
|
|
std::stringstream OS;
|
2003-02-04 00:03:18 +00:00
|
|
|
WriteAsOperand(OS, I->first, false, true, CurMod);
|
2002-11-18 21:42:45 +00:00
|
|
|
GW.emitSimpleNode(I->first, "", OS.str());
|
2002-11-02 00:13:20 +00:00
|
|
|
|
|
|
|
// Add edge from return node to real destination
|
2004-10-30 07:21:19 +00:00
|
|
|
DSNode *DestNode = I->second.getNode();
|
2002-11-06 06:20:27 +00:00
|
|
|
int EdgeDest = I->second.getOffset() >> DS::PointerShift;
|
2002-11-02 00:13:20 +00:00
|
|
|
if (EdgeDest == 0) EdgeDest = -1;
|
2004-10-30 07:21:19 +00:00
|
|
|
GW.emitEdge(I->first, -1, DestNode,
|
2002-11-02 00:13:20 +00:00
|
|
|
EdgeDest, "arrowtail=tee,color=gray63");
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2002-10-16 02:04:36 +00:00
|
|
|
// Output the returned value pointer...
|
2005-03-15 16:55:04 +00:00
|
|
|
for (DSGraph::retnodes_iterator I = G->retnodes_begin(),
|
|
|
|
E = G->retnodes_end(); I != E; ++I)
|
2003-06-30 03:15:25 +00:00
|
|
|
if (I->second.getNode()) {
|
|
|
|
std::string Label;
|
2005-03-15 16:55:04 +00:00
|
|
|
if (G->getReturnNodes().size() == 1)
|
2003-06-30 03:15:25 +00:00
|
|
|
Label = "returning";
|
|
|
|
else
|
|
|
|
Label = I->first->getName() + " ret node";
|
|
|
|
// Output the return node...
|
2003-11-12 04:58:19 +00:00
|
|
|
GW.emitSimpleNode((void*)I->first, "plaintext=circle", Label);
|
2003-06-30 03:15:25 +00:00
|
|
|
|
|
|
|
// Add edge from return node to real destination
|
2004-10-30 07:21:19 +00:00
|
|
|
DSNode *RetNode = I->second.getNode();
|
2003-06-30 03:15:25 +00:00
|
|
|
int RetEdgeDest = I->second.getOffset() >> DS::PointerShift;;
|
|
|
|
if (RetEdgeDest == 0) RetEdgeDest = -1;
|
2004-10-30 07:21:19 +00:00
|
|
|
GW.emitEdge((void*)I->first, -1, RetNode,
|
2003-06-30 03:15:25 +00:00
|
|
|
RetEdgeDest, "arrowtail=tee,color=gray63");
|
|
|
|
}
|
2002-10-16 20:16:16 +00:00
|
|
|
|
|
|
|
// Output all of the call nodes...
|
2005-01-30 23:51:02 +00:00
|
|
|
const std::list<DSCallSite> &FCs =
|
2002-11-10 06:53:59 +00:00
|
|
|
G->shouldPrintAuxCalls() ? G->getAuxFunctionCalls()
|
|
|
|
: G->getFunctionCalls();
|
2005-01-30 23:51:02 +00:00
|
|
|
for (std::list<DSCallSite>::const_iterator I = FCs.begin(), E = FCs.end();
|
|
|
|
I != E; ++I) {
|
|
|
|
const DSCallSite &Call = *I;
|
2003-02-05 21:59:58 +00:00
|
|
|
std::vector<std::string> EdgeSourceCaptions(Call.getNumPtrArgs()+2);
|
|
|
|
EdgeSourceCaptions[0] = "r";
|
|
|
|
if (Call.isDirectCall())
|
|
|
|
EdgeSourceCaptions[1] = Call.getCalleeFunc()->getName();
|
2003-02-14 20:25:47 +00:00
|
|
|
else
|
|
|
|
EdgeSourceCaptions[1] = "f";
|
2003-02-05 21:59:58 +00:00
|
|
|
|
|
|
|
GW.emitSimpleNode(&Call, "shape=record", "call", Call.getNumPtrArgs()+2,
|
|
|
|
&EdgeSourceCaptions);
|
2002-10-16 20:16:16 +00:00
|
|
|
|
2002-10-21 13:47:57 +00:00
|
|
|
if (DSNode *N = Call.getRetVal().getNode()) {
|
2002-11-06 06:20:27 +00:00
|
|
|
int EdgeDest = Call.getRetVal().getOffset() >> DS::PointerShift;
|
2002-10-21 13:47:57 +00:00
|
|
|
if (EdgeDest == 0) EdgeDest = -1;
|
2003-02-13 20:14:40 +00:00
|
|
|
GW.emitEdge(&Call, 0, N, EdgeDest, "color=gray63,tailclip=false");
|
2002-10-21 13:47:57 +00:00
|
|
|
}
|
2003-02-05 21:59:58 +00:00
|
|
|
|
|
|
|
// Print out the callee...
|
|
|
|
if (Call.isIndirectCall()) {
|
|
|
|
DSNode *N = Call.getCalleeNode();
|
|
|
|
assert(N && "Null call site callee node!");
|
2003-02-13 20:14:40 +00:00
|
|
|
GW.emitEdge(&Call, 1, N, -1, "color=gray63,tailclip=false");
|
2002-10-21 13:47:57 +00:00
|
|
|
}
|
2003-02-05 21:59:58 +00:00
|
|
|
|
2002-10-21 02:08:03 +00:00
|
|
|
for (unsigned j = 0, e = Call.getNumPtrArgs(); j != e; ++j)
|
|
|
|
if (DSNode *N = Call.getPtrArg(j).getNode()) {
|
2002-11-06 06:20:27 +00:00
|
|
|
int EdgeDest = Call.getPtrArg(j).getOffset() >> DS::PointerShift;
|
2002-10-16 20:16:16 +00:00
|
|
|
if (EdgeDest == 0) EdgeDest = -1;
|
2003-02-13 20:14:40 +00:00
|
|
|
GW.emitEdge(&Call, j+2, N, EdgeDest, "color=gray63,tailclip=false");
|
2002-10-16 20:16:16 +00:00
|
|
|
}
|
|
|
|
}
|
2002-10-16 02:04:36 +00:00
|
|
|
}
|
2002-10-13 19:31:57 +00:00
|
|
|
};
|
2003-11-12 23:11:14 +00:00
|
|
|
} // end namespace llvm
|
2002-10-13 19:31:57 +00:00
|
|
|
|
2002-10-17 01:02:46 +00:00
|
|
|
void DSNode::print(std::ostream &O, const DSGraph *G) const {
|
|
|
|
GraphWriter<const DSGraph *> W(O, G);
|
|
|
|
W.writeNode(this);
|
|
|
|
}
|
|
|
|
|
|
|
|
void DSGraph::print(std::ostream &O) const {
|
|
|
|
WriteGraph(O, this, "DataStructures");
|
|
|
|
}
|
2002-10-13 19:31:57 +00:00
|
|
|
|
2003-02-01 04:01:21 +00:00
|
|
|
void DSGraph::writeGraphToFile(std::ostream &O,
|
|
|
|
const std::string &GraphName) const {
|
|
|
|
std::string Filename = GraphName + ".dot";
|
2002-07-30 22:07:26 +00:00
|
|
|
O << "Writing '" << Filename << "'...";
|
|
|
|
std::ofstream F(Filename.c_str());
|
|
|
|
|
|
|
|
if (F.good()) {
|
2002-10-17 01:02:46 +00:00
|
|
|
print(F);
|
2002-11-11 00:01:02 +00:00
|
|
|
unsigned NumCalls = shouldPrintAuxCalls() ?
|
|
|
|
getAuxFunctionCalls().size() : getFunctionCalls().size();
|
|
|
|
O << " [" << getGraphSize() << "+" << NumCalls << "]\n";
|
2002-07-30 22:07:26 +00:00
|
|
|
} else {
|
|
|
|
O << " error opening file for writing!\n";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2003-02-10 18:17:07 +00:00
|
|
|
/// viewGraph - Emit a dot graph, run 'dot', run gv on the postscript file,
|
|
|
|
/// then cleanup. For use from the debugger.
|
|
|
|
///
|
|
|
|
void DSGraph::viewGraph() const {
|
|
|
|
std::ofstream F("/tmp/tempgraph.dot");
|
|
|
|
if (!F.good()) {
|
|
|
|
std::cerr << "Error opening '/tmp/tempgraph.dot' for temporary graph!\n";
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
print(F);
|
2003-02-11 19:27:27 +00:00
|
|
|
F.close();
|
2004-05-05 06:10:06 +00:00
|
|
|
if (system("dot -Tps -Gsize=10,7.5 -Grotate=90 /tmp/tempgraph.dot > /tmp/tempgraph.ps"))
|
2003-02-10 18:17:07 +00:00
|
|
|
std::cerr << "Error running dot: 'dot' not in path?\n";
|
|
|
|
system("gv /tmp/tempgraph.ps");
|
|
|
|
system("rm /tmp/tempgraph.dot /tmp/tempgraph.ps");
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2002-07-18 00:12:30 +00:00
|
|
|
template <typename Collection>
|
2002-07-27 01:12:15 +00:00
|
|
|
static void printCollection(const Collection &C, std::ostream &O,
|
2003-02-01 04:01:21 +00:00
|
|
|
const Module *M, const std::string &Prefix) {
|
2002-07-27 01:12:15 +00:00
|
|
|
if (M == 0) {
|
|
|
|
O << "Null Module pointer, cannot continue!\n";
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2002-11-07 02:18:46 +00:00
|
|
|
unsigned TotalNumNodes = 0, TotalCallNodes = 0;
|
2002-07-27 01:12:15 +00:00
|
|
|
for (Module::const_iterator I = M->begin(), E = M->end(); I != E; ++I)
|
2002-11-10 06:53:59 +00:00
|
|
|
if (C.hasGraph(*I)) {
|
2002-11-07 01:54:44 +00:00
|
|
|
DSGraph &Gr = C.getDSGraph((Function&)*I);
|
2002-11-07 02:18:46 +00:00
|
|
|
TotalNumNodes += Gr.getGraphSize();
|
2002-11-10 06:53:59 +00:00
|
|
|
unsigned NumCalls = Gr.shouldPrintAuxCalls() ?
|
|
|
|
Gr.getAuxFunctionCalls().size() : Gr.getFunctionCalls().size();
|
|
|
|
|
|
|
|
TotalCallNodes += NumCalls;
|
2005-02-01 19:10:48 +00:00
|
|
|
if (I->getName() == "main" || !OnlyPrintMain) {
|
2005-03-15 16:55:04 +00:00
|
|
|
Function *SCCFn = Gr.retnodes_begin()->first;
|
2005-02-01 19:10:48 +00:00
|
|
|
if (&*I == SCCFn)
|
|
|
|
Gr.writeGraphToFile(O, Prefix+I->getName());
|
|
|
|
else
|
|
|
|
O << "Didn't write '" << Prefix+I->getName()
|
|
|
|
<< ".dot' - Graph already emitted to '" << Prefix+SCCFn->getName()
|
|
|
|
<< "\n";
|
|
|
|
} else {
|
2002-11-07 01:54:44 +00:00
|
|
|
O << "Skipped Writing '" << Prefix+I->getName() << ".dot'... ["
|
2002-11-10 06:53:59 +00:00
|
|
|
<< Gr.getGraphSize() << "+" << NumCalls << "]\n";
|
2002-11-07 01:54:44 +00:00
|
|
|
}
|
2002-11-18 21:42:45 +00:00
|
|
|
|
2004-02-21 22:27:31 +00:00
|
|
|
unsigned GraphSize = Gr.getGraphSize();
|
2004-02-07 23:58:05 +00:00
|
|
|
if (MaxGraphSize < GraphSize) MaxGraphSize = GraphSize;
|
|
|
|
|
|
|
|
for (DSGraph::node_iterator NI = Gr.node_begin(), E = Gr.node_end();
|
|
|
|
NI != E; ++NI)
|
|
|
|
if ((*NI)->isNodeCompletelyFolded())
|
2002-11-18 21:42:45 +00:00
|
|
|
++NumFoldedNodes;
|
2002-11-07 01:54:44 +00:00
|
|
|
}
|
2002-11-07 02:18:46 +00:00
|
|
|
|
2002-11-09 21:12:07 +00:00
|
|
|
DSGraph &GG = C.getGlobalsGraph();
|
|
|
|
TotalNumNodes += GG.getGraphSize();
|
|
|
|
TotalCallNodes += GG.getFunctionCalls().size();
|
2002-11-09 21:40:58 +00:00
|
|
|
if (!OnlyPrintMain) {
|
2002-11-09 21:12:07 +00:00
|
|
|
GG.writeGraphToFile(O, Prefix+"GlobalsGraph");
|
|
|
|
} else {
|
|
|
|
O << "Skipped Writing '" << Prefix << "GlobalsGraph.dot'... ["
|
|
|
|
<< GG.getGraphSize() << "+" << GG.getFunctionCalls().size() << "]\n";
|
|
|
|
}
|
|
|
|
|
2002-11-07 02:18:46 +00:00
|
|
|
O << "\nGraphs contain [" << TotalNumNodes << "+" << TotalCallNodes
|
2002-11-08 01:21:07 +00:00
|
|
|
<< "] nodes total" << std::endl;
|
2002-07-10 22:38:08 +00:00
|
|
|
}
|
2002-07-18 00:12:30 +00:00
|
|
|
|
|
|
|
|
|
|
|
// print - Print out the analysis results...
|
2002-07-27 01:12:15 +00:00
|
|
|
void LocalDataStructures::print(std::ostream &O, const Module *M) const {
|
2004-01-22 13:42:43 +00:00
|
|
|
if (DontPrintAnything) return;
|
2002-10-01 22:33:50 +00:00
|
|
|
printCollection(*this, O, M, "ds.");
|
2002-07-18 00:12:30 +00:00
|
|
|
}
|
|
|
|
|
2002-07-27 01:12:15 +00:00
|
|
|
void BUDataStructures::print(std::ostream &O, const Module *M) const {
|
2004-01-22 13:42:43 +00:00
|
|
|
if (DontPrintAnything) return;
|
2002-10-01 22:33:50 +00:00
|
|
|
printCollection(*this, O, M, "bu.");
|
2002-07-30 22:07:26 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void TDDataStructures::print(std::ostream &O, const Module *M) const {
|
2004-01-22 13:42:43 +00:00
|
|
|
if (DontPrintAnything) return;
|
2002-10-01 22:33:50 +00:00
|
|
|
printCollection(*this, O, M, "td.");
|
2002-10-17 04:24:30 +00:00
|
|
|
}
|
2003-11-11 22:41:34 +00:00
|
|
|
|
2003-11-13 05:05:41 +00:00
|
|
|
void CompleteBUDataStructures::print(std::ostream &O, const Module *M) const {
|
2004-01-22 13:42:43 +00:00
|
|
|
if (DontPrintAnything) return;
|
2003-11-13 05:05:41 +00:00
|
|
|
printCollection(*this, O, M, "cbu.");
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2005-03-13 19:51:24 +00:00
|
|
|
void EquivClassGraphs::print(std::ostream &O, const Module *M) const {
|
|
|
|
if (DontPrintAnything) return;
|
|
|
|
printCollection(*this, O, M, "eq.");
|
|
|
|
}
|
|
|
|
|