diff options
author | Chris Lattner <sabre@nondot.org> | 2010-03-29 01:40:38 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-03-29 01:40:38 +0000 |
commit | 48e86dbe29e331357b0df11075b7974009c65f34 (patch) | |
tree | 0836a880998c3008c0445c5148e1ab0a5745ce11 /utils/TableGen/CodeGenDAGPatterns.h | |
parent | 79c4d820b46cee1e78ecdef80b3f2ed6373839b7 (diff) |
print the complexity of the pattern being matched in the
comment in the generated table.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99794 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen/CodeGenDAGPatterns.h')
-rw-r--r-- | utils/TableGen/CodeGenDAGPatterns.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/utils/TableGen/CodeGenDAGPatterns.h b/utils/TableGen/CodeGenDAGPatterns.h index 0960647300..548051300d 100644 --- a/utils/TableGen/CodeGenDAGPatterns.h +++ b/utils/TableGen/CodeGenDAGPatterns.h @@ -598,6 +598,10 @@ public: unsigned getAddedComplexity() const { return AddedComplexity; } std::string getPredicateCheck() const; + + /// Compute the complexity metric for the input pattern. This roughly + /// corresponds to the number of nodes that are covered. + unsigned getPatternComplexity(const CodeGenDAGPatterns &CGP) const; }; // Deterministic comparison of Record*. |