aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2017-08-02 06:52:26 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2017-08-02 06:52:26 +0000
commit232b2c6e1df5b174e1b73db29e71ddccb15ad5e1 (patch)
treeff11a30c384951bb9332e4d8c7e124e25455f1d9 /gcc
parent77eefb7122d544b9e22a7f40a92320742c23e74b (diff)
downloadgcc-232b2c6e1df5b174e1b73db29e71ddccb15ad5e1.zip
gcc-232b2c6e1df5b174e1b73db29e71ddccb15ad5e1.tar.gz
gcc-232b2c6e1df5b174e1b73db29e71ddccb15ad5e1.tar.bz2
tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline into ...
2017-08-02 Richard Biener <rguenther@suse.de> * tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline into ... (bitmap_insert_into_set): ... this. From-SVN: r250812
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/tree-ssa-pre.c26
2 files changed, 16 insertions, 16 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 574745f..46d3397 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,11 @@
2017-08-02 Richard Biener <rguenther@suse.de>
+ * tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline
+ into ...
+ (bitmap_insert_into_set): ... this.
+
+2017-08-02 Richard Biener <rguenther@suse.de>
+
PR tree-optimization/81633
Revert
2015-08-17 Alan Hayward <alan.hayward@arm.com>
diff --git a/gcc/tree-ssa-pre.c b/gcc/tree-ssa-pre.c
index afe898b..a6a68cf 100644
--- a/gcc/tree-ssa-pre.c
+++ b/gcc/tree-ssa-pre.c
@@ -540,8 +540,6 @@ static void bitmap_set_copy (bitmap_set_t, bitmap_set_t);
static void bitmap_set_and (bitmap_set_t, bitmap_set_t);
static bool bitmap_set_contains_value (bitmap_set_t, unsigned int);
static void bitmap_insert_into_set (bitmap_set_t, pre_expr);
-static void bitmap_insert_into_set_1 (bitmap_set_t, pre_expr,
- unsigned int, bool);
static bitmap_set_t bitmap_set_new (void);
static tree create_expression_by_pieces (basic_block, pre_expr, gimple_seq *,
tree);
@@ -732,27 +730,22 @@ bitmap_remove_from_set (bitmap_set_t set, pre_expr expr)
}
}
+/* Insert an expression EXPR into a bitmapped set. */
+
static void
-bitmap_insert_into_set_1 (bitmap_set_t set, pre_expr expr,
- unsigned int val, bool allow_constants)
+bitmap_insert_into_set (bitmap_set_t set, pre_expr expr)
{
- if (allow_constants || !value_id_constant_p (val))
+ unsigned int val = get_expr_value_id (expr);
+ if (! value_id_constant_p (val))
{
- /* We specifically expect this and only this function to be able to
- insert constants into a set. */
+ /* Note this is the only function causing multiple expressions
+ for the same value to appear in a set. This is needed for
+ TMP_GEN, PHI_GEN and NEW_SETs. */
bitmap_set_bit (&set->values, val);
bitmap_set_bit (&set->expressions, get_or_alloc_expression_id (expr));
}
}
-/* Insert an expression EXPR into a bitmapped set. */
-
-static void
-bitmap_insert_into_set (bitmap_set_t set, pre_expr expr)
-{
- bitmap_insert_into_set_1 (set, expr, get_expr_value_id (expr), false);
-}
-
/* Copy a bitmapped set ORIG, into bitmapped set DEST. */
static void
@@ -2471,7 +2464,8 @@ compute_antic (void)
{
/* For partial antic we ignore backedges and thus we do not need
to perform any iteration when we process blocks in postorder. */
- int postorder_num = pre_and_rev_post_order_compute (NULL, postorder.address (), false);
+ int postorder_num
+ = pre_and_rev_post_order_compute (NULL, postorder.address (), false);
for (i = postorder_num - 1 ; i >= 0; i--)
{
basic_block block = BASIC_BLOCK_FOR_FN (cfun, postorder[i]);