diff options
author | Chris Lattner <sabre@nondot.org> | 2002-10-03 21:55:13 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2002-10-03 21:55:13 +0000 |
commit | 6727ec64e8f2892dfdd0864a0ed05796f0716e31 (patch) | |
tree | c30c5e5b946a27eab8c76ec8f82e53932216877d /lib/Analysis/DataStructure/Printer.cpp | |
parent | b0d0f5b473b6110a9e72d823f2f2c4c52928a1bf (diff) |
sgefa uses truely huge data structures nodes. Only print part of them if they
are so big
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4035 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/DataStructure/Printer.cpp')
-rw-r--r-- | lib/Analysis/DataStructure/Printer.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/Analysis/DataStructure/Printer.cpp b/lib/Analysis/DataStructure/Printer.cpp index b78861c134..51ebe632eb 100644 --- a/lib/Analysis/DataStructure/Printer.cpp +++ b/lib/Analysis/DataStructure/Printer.cpp @@ -103,17 +103,22 @@ void DSNode::print(std::ostream &O, const DSGraph *G) const { O << "\tNode" << (void*)this << " [ label =\"{" << Caption; + unsigned Size = getSize(); + if (Size > 64) Size = 64; // Don't print out HUGE graph nodes! + if (getSize() != 0) { O << "|{"; - for (unsigned i = 0; i < getSize(); ++i) { + for (unsigned i = 0; i < Size; ++i) { if (i) O << "|"; O << "<g" << i << ">" << (int)MergeMap[i]; } + if (Size != getSize()) + O << "|truncated..."; O << "}"; } O << "}\"];\n"; - for (unsigned i = 0; i != getSize(); ++i) + for (unsigned i = 0; i != Size; ++i) if (const DSNodeHandle *DSN = getLink(i)) writeEdge(O, this, ":g", i, *DSN); } |