re PR tree-optimization/77677 (ICE at -O1 and above in both 32-bit and 64-bit modes...
authorRichard Biener <rguenther@suse.de>
Thu, 22 Sep 2016 12:16:12 +0000 (12:16 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Thu, 22 Sep 2016 12:16:12 +0000 (12:16 +0000)
2016-09-22  Richard Biener  <rguenther@suse.de>

PR middle-end/77677
* gimple-match-head.c (gimple_resimplify1): Drop TREE_OVERFLOW
from constant folding results.
(gimple_resimplify2): Likewise.
(gimple_resimplify3): Likewise.

From-SVN: r240352

gcc/ChangeLog
gcc/gimple-match-head.c

index 9b1792596fc0da72d10700a47c54f79cbf2d6d5e..3bd4139b3b570f6658acb7c7004b543f70ad17d7 100644 (file)
@@ -1,3 +1,11 @@
+2016-09-22  Richard Biener  <rguenther@suse.de>
+
+       PR middle-end/77677
+       * gimple-match-head.c (gimple_resimplify1): Drop TREE_OVERFLOW
+       from constant folding results.
+       (gimple_resimplify2): Likewise.
+       (gimple_resimplify3): Likewise.
+
 2016-09-22  Richard Biener  <rguenther@suse.de>
 
        PR middle-end/77678
index 2beadbc29054d4bcb8678d6dbac04401224735b1..4eab90d8f6debb7d34b095fed4b9e4eafd82cd1f 100644 (file)
@@ -89,6 +89,8 @@ gimple_resimplify1 (gimple_seq *seq,
       if (tem != NULL_TREE
          && CONSTANT_CLASS_P (tem))
        {
+         if (TREE_OVERFLOW_P (tem))
+           tem = drop_tree_overflow (tem);
          res_ops[0] = tem;
          res_ops[1] = NULL_TREE;
          res_ops[2] = NULL_TREE;
@@ -134,6 +136,8 @@ gimple_resimplify2 (gimple_seq *seq,
       if (tem != NULL_TREE
          && CONSTANT_CLASS_P (tem))
        {
+         if (TREE_OVERFLOW_P (tem))
+           tem = drop_tree_overflow (tem);
          res_ops[0] = tem;
          res_ops[1] = NULL_TREE;
          res_ops[2] = NULL_TREE;
@@ -194,6 +198,8 @@ gimple_resimplify3 (gimple_seq *seq,
       if (tem != NULL_TREE
          && CONSTANT_CLASS_P (tem))
        {
+         if (TREE_OVERFLOW_P (tem))
+           tem = drop_tree_overflow (tem);
          res_ops[0] = tem;
          res_ops[1] = NULL_TREE;
          res_ops[2] = NULL_TREE;