From 6a6dd6f487bfda1fe8fbb4ab7cb0a9fa1fbadbcf Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 11 Feb 2004 20:44:17 +0000 Subject: [PATCH] If a node has more than 64 outgoing edges, make the edges go from the 'truncated' block, instead of dropping them entirely. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11334 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/Support/GraphWriter.h | 4 +++- include/llvm/Support/GraphWriter.h | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/include/Support/GraphWriter.h b/include/Support/GraphWriter.h index 0eace78d73f..c6a5c3cdc94 100644 --- a/include/Support/GraphWriter.h +++ b/include/Support/GraphWriter.h @@ -117,7 +117,7 @@ public: } if (EI != EE) - O << "|truncated..."; + O << "|truncated..."; O << "}"; } O << "}\"];\n"; // Finish printing the "node" line @@ -126,6 +126,8 @@ public: EI = GTraits::child_begin(Node); for (unsigned i = 0; EI != EE && i != 64; ++EI, ++i) writeEdge(Node, i, EI); + for (; EI != EE; ++EI) + writeEdge(Node, 64, EI); } void writeEdge(NodeType *Node, unsigned edgeidx, child_iterator EI) { diff --git a/include/llvm/Support/GraphWriter.h b/include/llvm/Support/GraphWriter.h index 0eace78d73f..c6a5c3cdc94 100644 --- a/include/llvm/Support/GraphWriter.h +++ b/include/llvm/Support/GraphWriter.h @@ -117,7 +117,7 @@ public: } if (EI != EE) - O << "|truncated..."; + O << "|truncated..."; O << "}"; } O << "}\"];\n"; // Finish printing the "node" line @@ -126,6 +126,8 @@ public: EI = GTraits::child_begin(Node); for (unsigned i = 0; EI != EE && i != 64; ++EI, ++i) writeEdge(Node, i, EI); + for (; EI != EE; ++EI) + writeEdge(Node, 64, EI); } void writeEdge(NodeType *Node, unsigned edgeidx, child_iterator EI) {