diff options
Diffstat (limited to 'gcc/tree-chrec.c')
-rw-r--r-- | gcc/tree-chrec.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/gcc/tree-chrec.c b/gcc/tree-chrec.c index c945f93..929bbc0 100644 --- a/gcc/tree-chrec.c +++ b/gcc/tree-chrec.c @@ -1529,14 +1529,12 @@ evolution_function_right_is_integer_cst (const_tree chrec) return true; case POLYNOMIAL_CHREC: - if (!evolution_function_right_is_integer_cst (CHREC_RIGHT (chrec))) - return false; - - if (TREE_CODE (CHREC_LEFT (chrec)) == POLYNOMIAL_CHREC - && !evolution_function_right_is_integer_cst (CHREC_LEFT (chrec))) - return false; + return TREE_CODE (CHREC_RIGHT (chrec)) == INTEGER_CST + && (TREE_CODE (CHREC_LEFT (chrec)) != POLYNOMIAL_CHREC + || evolution_function_right_is_integer_cst (CHREC_LEFT (chrec))); - return true; + CASE_CONVERT: + return evolution_function_right_is_integer_cst (TREE_OPERAND (chrec, 0)); default: return false; |