TableGen: Allow AddedComplexity values to be negative
[oota-llvm.git] / utils / TableGen / CodeGenDAGPatterns.cpp
index 2602bbcf6f61c20be64eb9876f8f9dab1117a90b..d195ba823b5bf368d976558e36292b7a22cb23bd 100644 (file)
@@ -771,7 +771,7 @@ static unsigned getPatternSize(const TreePatternNode *P,
 
 /// Compute the complexity metric for the input pattern.  This roughly
 /// corresponds to the number of nodes that are covered.
-unsigned PatternToMatch::
+int PatternToMatch::
 getPatternComplexity(const CodeGenDAGPatterns &CGP) const {
   return getPatternSize(getSrcPattern(), CGP) + getAddedComplexity();
 }