aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-predcom.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-predcom.c')
-rw-r--r--gcc/tree-predcom.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree-predcom.c b/gcc/tree-predcom.c
index e7b10cb..fdb32f1 100644
--- a/gcc/tree-predcom.c
+++ b/gcc/tree-predcom.c
@@ -1655,7 +1655,8 @@ is_inv_store_elimination_chain (struct loop *loop, chain_p chain)
/* If loop iterates for unknown times or fewer times than chain->lenght,
we still need to setup root variable and propagate it with PHI node. */
tree niters = number_of_latch_executions (loop);
- if (TREE_CODE (niters) != INTEGER_CST || wi::leu_p (niters, chain->length))
+ if (TREE_CODE (niters) != INTEGER_CST
+ || wi::leu_p (wi::to_wide (niters), chain->length))
return false;
/* Check stores in chain for elimination if they only store loop invariant