]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
gimplify.c (gimplify_expr): Drop TREE_OVERFLOW from INTEGER_CSTs.
authorJakub Jelinek <jakub@redhat.com>
Mon, 20 Oct 2008 22:57:27 +0000 (00:57 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Mon, 20 Oct 2008 22:57:27 +0000 (00:57 +0200)
* gimplify.c (gimplify_expr): Drop TREE_OVERFLOW from
INTEGER_CSTs.

From-SVN: r141251

gcc/ChangeLog
gcc/gimplify.c

index ce553c6bf83fa8ced853a2e0a0f2a9ef348556c5..c55ccfaae0b11319a45dd2de2d1eb13dd7877915 100644 (file)
@@ -1,3 +1,8 @@
+2008-10-21  Jakub Jelinek  <jakub@redhat.com>
+
+       * gimplify.c (gimplify_expr): Drop TREE_OVERFLOW from
+       INTEGER_CSTs.
+
 2008-10-20  Daniel Berlin  <dberlin@dberlin.org>
 
        * tree-ssa-pre.c (insert_into_preds_of_block): Don't rewrite constant
index c6a79fbe8b7c5c78b06b6f7138b8d92f211f34f3..d2625a7f7152afd8e1049ad48d3e6e6dca19d336 100644 (file)
@@ -6441,6 +6441,16 @@ gimplify_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
 
          /* Constants need not be gimplified.  */
        case INTEGER_CST:
+         /* Don't preserve TREE_OVERFLOW flags, it only inhibits
+            many optimizations and FEs should have taken care of
+            reporting all the required diagnostics.  */
+         if (TREE_OVERFLOW (*expr_p))
+           *expr_p = build_int_cst_wide (TREE_TYPE (*expr_p),
+                                         TREE_INT_CST_LOW (*expr_p),
+                                         TREE_INT_CST_HIGH (*expr_p));
+         ret = GS_ALL_DONE;
+         break;
+
        case REAL_CST:
        case FIXED_CST:
        case STRING_CST: