Commit ff88c5aa by Zdenek Dvorak Committed by Zdenek Dvorak

tree-flow.h (struct stmt_ann_d): Remove makes_aliased_loads and makes_aliased_stores fields.

	* tree-flow.h (struct stmt_ann_d): Remove
	makes_aliased_loads and makes_aliased_stores fields.
	* tree-ssa-ccp.c (likely_value): Do not use makes_aliased_stores
	and makes_aliased_loads fields.
	* tree-ssa-dom.c (eliminate_redundant_computations): Do not
	use makes_aliased_stores.
	* tree-ssa-operands.c (clobbered_aliased_loads,
	clobbered_aliased_stores, ro_call_aliased_loads): Removed.
	(build_ssa_operands, add_stmt_operand, add_call_clobber_ops,
	add_call_read_ops): Do not set makes_aliased_stores and
	makes_aliased_loads fields.
	* tree-ssa.c (verify_ssa): Do not verify makes_aliased_stores
	field.

From-SVN: r108766
parent 56c779bc
2005-12-19 Zdenek Dvorak <dvorakz@suse.cz>
* tree-flow.h (struct stmt_ann_d): Remove
makes_aliased_loads and makes_aliased_stores fields.
* tree-ssa-ccp.c (likely_value): Do not use makes_aliased_stores
and makes_aliased_loads fields.
* tree-ssa-dom.c (eliminate_redundant_computations): Do not
use makes_aliased_stores.
* tree-ssa-operands.c (clobbered_aliased_loads,
clobbered_aliased_stores, ro_call_aliased_loads): Removed.
(build_ssa_operands, add_stmt_operand, add_call_clobber_ops,
add_call_read_ops): Do not set makes_aliased_stores and
makes_aliased_loads fields.
* tree-ssa.c (verify_ssa): Do not verify makes_aliased_stores
field.
2005-12-18 Geoffrey Keating <geoffk@apple.com> 2005-12-18 Geoffrey Keating <geoffk@apple.com>
* config/darwin.h: Don't include darwin-sections.def to declare * config/darwin.h: Don't include darwin-sections.def to declare
......
...@@ -256,12 +256,6 @@ struct stmt_ann_d GTY(()) ...@@ -256,12 +256,6 @@ struct stmt_ann_d GTY(())
need to be scanned again). */ need to be scanned again). */
unsigned modified : 1; unsigned modified : 1;
/* Nonzero if the statement makes aliased loads. */
unsigned makes_aliased_loads : 1;
/* Nonzero if the statement makes aliased stores. */
unsigned makes_aliased_stores : 1;
/* Nonzero if the statement makes references to volatile storage. */ /* Nonzero if the statement makes references to volatile storage. */
unsigned has_volatile_ops : 1; unsigned has_volatile_ops : 1;
......
...@@ -482,9 +482,7 @@ likely_value (tree stmt) ...@@ -482,9 +482,7 @@ likely_value (tree stmt)
/* If we are not doing store-ccp, statements with loads /* If we are not doing store-ccp, statements with loads
and/or stores will never fold into a constant. */ and/or stores will never fold into a constant. */
if (!do_store_ccp if (!do_store_ccp
&& (ann->makes_aliased_stores && !ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS))
|| ann->makes_aliased_loads
|| !ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS)))
return VARYING; return VARYING;
......
...@@ -2394,8 +2394,7 @@ eliminate_redundant_computations (tree stmt, stmt_ann_t ann) ...@@ -2394,8 +2394,7 @@ eliminate_redundant_computations (tree stmt, stmt_ann_t ann)
/* Certain expressions on the RHS can be optimized away, but can not /* Certain expressions on the RHS can be optimized away, but can not
themselves be entered into the hash tables. */ themselves be entered into the hash tables. */
if (ann->makes_aliased_stores if (! def
|| ! def
|| TREE_CODE (def) != SSA_NAME || TREE_CODE (def) != SSA_NAME
|| SSA_NAME_OCCURS_IN_ABNORMAL_PHI (def) || SSA_NAME_OCCURS_IN_ABNORMAL_PHI (def)
|| !ZERO_SSA_OPERANDS (stmt, SSA_OP_VMAYDEF) || !ZERO_SSA_OPERANDS (stmt, SSA_OP_VMAYDEF)
......
...@@ -127,9 +127,6 @@ bool ssa_ro_call_cache_valid; ...@@ -127,9 +127,6 @@ bool ssa_ro_call_cache_valid;
static VEC(tree,heap) *clobbered_v_may_defs; static VEC(tree,heap) *clobbered_v_may_defs;
static VEC(tree,heap) *clobbered_vuses; static VEC(tree,heap) *clobbered_vuses;
static VEC(tree,heap) *ro_call_vuses; static VEC(tree,heap) *ro_call_vuses;
static bool clobbered_aliased_loads;
static bool clobbered_aliased_stores;
static bool ro_call_aliased_loads;
static bool ops_active = false; static bool ops_active = false;
static GTY (()) struct ssa_operand_memory_d *operand_memory = NULL; static GTY (()) struct ssa_operand_memory_d *operand_memory = NULL;
...@@ -798,14 +795,9 @@ build_ssa_operands (tree stmt) ...@@ -798,14 +795,9 @@ build_ssa_operands (tree stmt)
{ {
stmt_ann_t ann = get_stmt_ann (stmt); stmt_ann_t ann = get_stmt_ann (stmt);
/* Initially assume that the statement has no volatile operands, nor /* Initially assume that the statement has no volatile operands. */
makes aliased loads or stores. */
if (ann) if (ann)
{ ann->has_volatile_ops = false;
ann->has_volatile_ops = false;
ann->makes_aliased_stores = false;
ann->makes_aliased_loads = false;
}
start_ssa_stmt_operands (); start_ssa_stmt_operands ();
...@@ -1643,11 +1635,7 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags) ...@@ -1643,11 +1635,7 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags)
} }
} }
else else
{ append_vuse (var);
append_vuse (var);
if (s_ann && v_ann->is_alias_tag)
s_ann->makes_aliased_loads = 1;
}
} }
else else
{ {
...@@ -1668,9 +1656,6 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags) ...@@ -1668,9 +1656,6 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags)
for (i = 0; i < VARRAY_ACTIVE_SIZE (aliases); i++) for (i = 0; i < VARRAY_ACTIVE_SIZE (aliases); i++)
append_v_may_def (VARRAY_TREE (aliases, i)); append_v_may_def (VARRAY_TREE (aliases, i));
if (s_ann)
s_ann->makes_aliased_stores = 1;
} }
else else
{ {
...@@ -1681,9 +1666,6 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags) ...@@ -1681,9 +1666,6 @@ add_stmt_operand (tree *var_p, stmt_ann_t s_ann, int flags)
for (i = 0; i < VARRAY_ACTIVE_SIZE (aliases); i++) for (i = 0; i < VARRAY_ACTIVE_SIZE (aliases); i++)
append_vuse (VARRAY_TREE (aliases, i)); append_vuse (VARRAY_TREE (aliases, i));
if (s_ann)
s_ann->makes_aliased_loads = 1;
} }
} }
} }
...@@ -1792,11 +1774,6 @@ add_call_clobber_ops (tree stmt, tree callee) ...@@ -1792,11 +1774,6 @@ add_call_clobber_ops (tree stmt, tree callee)
var_ann (t)->in_v_may_def_list = 1; var_ann (t)->in_v_may_def_list = 1;
VEC_safe_push (tree, heap, build_v_may_defs, (tree)t); VEC_safe_push (tree, heap, build_v_may_defs, (tree)t);
} }
if (s_ann)
{
s_ann->makes_aliased_loads = clobbered_aliased_loads;
s_ann->makes_aliased_stores = clobbered_aliased_stores;
}
return; return;
} }
...@@ -1828,16 +1805,6 @@ add_call_clobber_ops (tree stmt, tree callee) ...@@ -1828,16 +1805,6 @@ add_call_clobber_ops (tree stmt, tree callee)
if ((!not_read_b || bitmap_empty_p (not_read_b)) if ((!not_read_b || bitmap_empty_p (not_read_b))
&& (!not_written_b || bitmap_empty_p (not_written_b))) && (!not_written_b || bitmap_empty_p (not_written_b)))
{ {
clobbered_aliased_loads = empty_ann.makes_aliased_loads;
clobbered_aliased_stores = empty_ann.makes_aliased_stores;
/* Set the flags for a stmt's annotation. */
if (s_ann)
{
s_ann->makes_aliased_loads = empty_ann.makes_aliased_loads;
s_ann->makes_aliased_stores = empty_ann.makes_aliased_stores;
}
/* Prepare empty cache vectors. */ /* Prepare empty cache vectors. */
VEC_truncate (tree, clobbered_vuses, 0); VEC_truncate (tree, clobbered_vuses, 0);
VEC_truncate (tree, clobbered_v_may_defs, 0); VEC_truncate (tree, clobbered_v_may_defs, 0);
...@@ -1893,8 +1860,6 @@ add_call_read_ops (tree stmt) ...@@ -1893,8 +1860,6 @@ add_call_read_ops (tree stmt)
var_ann (t)->in_vuse_list = 1; var_ann (t)->in_vuse_list = 1;
VEC_safe_push (tree, heap, build_vuses, (tree)t); VEC_safe_push (tree, heap, build_vuses, (tree)t);
} }
if (s_ann)
s_ann->makes_aliased_loads = ro_call_aliased_loads;
return; return;
} }
...@@ -1907,10 +1872,6 @@ add_call_read_ops (tree stmt) ...@@ -1907,10 +1872,6 @@ add_call_read_ops (tree stmt)
add_stmt_operand (&var, &empty_ann, opf_none | opf_non_specific); add_stmt_operand (&var, &empty_ann, opf_none | opf_non_specific);
} }
ro_call_aliased_loads = empty_ann.makes_aliased_loads;
if (s_ann)
s_ann->makes_aliased_loads = empty_ann.makes_aliased_loads;
/* Prepare empty cache vectors. */ /* Prepare empty cache vectors. */
VEC_truncate (tree, ro_call_vuses, 0); VEC_truncate (tree, ro_call_vuses, 0);
......
...@@ -730,15 +730,6 @@ verify_ssa (bool check_modified_stmt) ...@@ -730,15 +730,6 @@ verify_ssa (bool check_modified_stmt)
} }
} }
if (stmt_ann (stmt)->makes_aliased_stores
&& ZERO_SSA_OPERANDS (stmt, SSA_OP_VMAYDEF))
{
error ("statement makes aliased stores, but has no V_MAY_DEFS");
print_generic_stmt (stderr, stmt, TDF_VOPS);
goto err;
}
FOR_EACH_SSA_USE_OPERAND (use_p, stmt, iter, FOR_EACH_SSA_USE_OPERAND (use_p, stmt, iter,
SSA_OP_ALL_USES | SSA_OP_ALL_KILLS) SSA_OP_ALL_USES | SSA_OP_ALL_KILLS)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment