diff options
author | David Greene <greened@obbligato.org> | 2010-01-19 20:37:34 +0000 |
---|---|---|
committer | David Greene <greened@obbligato.org> | 2010-01-19 20:37:34 +0000 |
commit | ce6715faa37b2e44edcf400084aa808ae30d7085 (patch) | |
tree | 48d9e0200f70bd00635046cdf2fb9f6ab109effd /include | |
parent | b9a25b7744ed12b80031426978decce3d4cebbd7 (diff) | |
download | external_llvm-ce6715faa37b2e44edcf400084aa808ae30d7085.zip external_llvm-ce6715faa37b2e44edcf400084aa808ae30d7085.tar.gz external_llvm-ce6715faa37b2e44edcf400084aa808ae30d7085.tar.bz2 |
Add some new debugging APIs to print out "raw" SelectionDAGs to make
understanding CannotYTetSelect and other errors easier.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93901 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/CodeGen/SelectionDAGNodes.h | 48 |
1 files changed, 33 insertions, 15 deletions
diff --git a/include/llvm/CodeGen/SelectionDAGNodes.h b/include/llvm/CodeGen/SelectionDAGNodes.h index 964b498..6a53155 100644 --- a/include/llvm/CodeGen/SelectionDAGNodes.h +++ b/include/llvm/CodeGen/SelectionDAGNodes.h @@ -1285,37 +1285,55 @@ public: void print_details(raw_ostream &OS, const SelectionDAG *G) const; void print(raw_ostream &OS, const SelectionDAG *G = 0) const; void printr(raw_ostream &OS, const SelectionDAG *G = 0) const; - /// printWithDepth - Print a SelectionDAG node and children up to - /// depth "depth." "limit" controls whether a message should be - /// printed if we hit depth "depth." + + /// printrFull - Print a SelectionDAG node and all children down to + /// the leaves. The given SelectionDAG allows target-specific nodes + /// to be printed in human-readable form. Unlike printr, this will + /// print the whole DAG, including children that appear multiple + /// times. /// - void printWithDepth(raw_ostream &O, const SelectionDAG *G = 0, - unsigned depth = -1, unsigned indent = 0, - bool limit = false) const; - /// printWithFullDepth - Print a SelectionDAG node and all children - /// down to the leaves. + void printrFull(raw_ostream &O, const SelectionDAG *G = 0) const; + + /// printrWithDepth - Print a SelectionDAG node and children up to + /// depth "depth." The given SelectionDAG allows target-specific + /// nodes to be printed in human-readable form. Unlike printr, this + /// will print children that appear multiple times wherever they are + /// used. /// - void printWithFullDepth(raw_ostream &O, const SelectionDAG *G = 0, - unsigned indent = 0) const; + void printrWithDepth(raw_ostream &O, const SelectionDAG *G = 0, + unsigned depth = 100) const; + + /// dump - Dump this node, for debugging. void dump() const; + /// dumpr - Dump (recursively) this node and its use-def subgraph. void dumpr() const; + /// dump - Dump this node, for debugging. /// The given SelectionDAG allows target-specific nodes to be printed /// in human-readable form. void dump(const SelectionDAG *G) const; + /// dumpr - Dump (recursively) this node and its use-def subgraph. /// The given SelectionDAG allows target-specific nodes to be printed /// in human-readable form. void dumpr(const SelectionDAG *G) const; - /// dumpWithDepth - printWithDepth to dbgs(). + + /// dumprFull - printrFull to dbgs(). The given SelectionDAG allows + /// target-specific nodes to be printed in human-readable form. + /// Unlike dumpr, this will print the whole DAG, including children + /// that appear multiple times. /// - void dumpWithDepth(const SelectionDAG *G = 0, unsigned depth = 1, - unsigned indent = 0, bool limit = false) const; - /// dumpWithFullDepth - printWithFullDepth to dbgs(). + void dumprFull(const SelectionDAG *G = 0) const; + + /// dumprWithDepth - printrWithDepth to dbgs(). The given + /// SelectionDAG allows target-specific nodes to be printed in + /// human-readable form. Unlike dumpr, this will print children + /// that appear multiple times wherever they are used. /// - void dumpWithFullDepth(const SelectionDAG *G = 0, unsigned indent = 0) const; + void dumprWithDepth(const SelectionDAG *G = 0, unsigned depth = 100) const; + static bool classof(const SDNode *) { return true; } |