aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2019-01-24 20:49:09 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2019-01-24 20:49:09 +0100
commitf359ba2fa911fd73bb5d22592c695ed5ab497b0e (patch)
treed9f75e5c617e4f860d7919bb3cbc55605048ff65 /gcc
parent3b4218cc9f243cfe796dd933e8d0abd9c610503e (diff)
downloadgcc-f359ba2fa911fd73bb5d22592c695ed5ab497b0e.zip
gcc-f359ba2fa911fd73bb5d22592c695ed5ab497b0e.tar.gz
gcc-f359ba2fa911fd73bb5d22592c695ed5ab497b0e.tar.bz2
re PR tree-optimization/88964 (ICE in wide_int_to_tree_1, at tree.c:1561)
PR tree-optimization/88964 * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Also punt if HONOR_SNANS (chrec). From-SVN: r268247
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/gimple-loop-interchange.cc4
2 files changed, 6 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 7087ef1..03d1b33 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,9 @@
2019-01-24 Jakub Jelinek <jakub@redhat.com>
+ PR tree-optimization/88964
+ * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Also
+ punt if HONOR_SNANS (chrec).
+
PR middle-end/89015
* tree-nested.c (convert_nonlocal_reference_stmt,
convert_local_reference_stmt, convert_tramp_reference_stmt,
diff --git a/gcc/gimple-loop-interchange.cc b/gcc/gimple-loop-interchange.cc
index 1f0e49d..b188ce8 100644
--- a/gcc/gimple-loop-interchange.cc
+++ b/gcc/gimple-loop-interchange.cc
@@ -690,8 +690,8 @@ loop_cand::analyze_induction_var (tree var, tree chrec)
{
/* Punt on floating point invariants if honoring signed zeros,
representing that as + 0.0 would change the result if init
- is -0.0. */
- if (HONOR_SIGNED_ZEROS (chrec))
+ is -0.0. Similarly for SNaNs it can raise exception. */
+ if (HONOR_SIGNED_ZEROS (chrec) || HONOR_SNANS (chrec))
return false;
struct induction *iv = XCNEW (struct induction);
iv->var = var;