]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* tree-scalar-evoluiton.c (simple_iv): Use nowrap_type to check if
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 5 Jul 2016 16:02:52 +0000 (16:02 +0000)
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 5 Jul 2016 16:02:52 +0000 (16:02 +0000)
IV can overflow.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@238009 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/tree-scalar-evolution.c

index 135fd5b678bd5de226dbd119a0e7e2a78cb8a455..5e466b7cd7d661823a45bc1fa5d503f4794ac15b 100644 (file)
@@ -1,3 +1,8 @@
+2016-07-05  Jan Hubicka  <jh@suse.cz>
+
+       * tree-scalar-evoluiton.c (simple_iv): Use nowrap_type to check if
+       IV can overflow.
+
 2016-07-05  Richard Biener  <rguenther@suse.de>
 
        * gimple-ssa-split-paths.c (find_block_to_duplicate_for_splitting_pa):
index d6f2a2fba1403b80cf5defda8f705f3f1b1d7a1a..7c4c433672826da676d3abc54b62d0fff8a51e7f 100644 (file)
@@ -3375,8 +3375,7 @@ simple_iv (struct loop *wrto_loop, struct loop *use_loop, tree op,
   if (tree_contains_chrecs (iv->base, NULL))
     return false;
 
-  iv->no_overflow = (!folded_casts && ANY_INTEGRAL_TYPE_P (type)
-                    && TYPE_OVERFLOW_UNDEFINED (type));
+  iv->no_overflow = !folded_casts && nowrap_type_p (type);
 
   /* Try to simplify iv base: