summaryrefslogtreecommitdiff
path: root/gcc/tree-dfa.c
diff options
context:
space:
mode:
authordnovillo <dnovillo@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-18 18:21:23 +0000
committerdnovillo <dnovillo@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-18 18:21:23 +0000
commit76b883382f782f411cc529f126397e9fb99a0f45 (patch)
tree44097e1b0caa8eb28b72d009d6ad0158ac4c06a9 /gcc/tree-dfa.c
parent5d179ab5b1030e0a55da8403ba6e29bb54556e80 (diff)
downloadgcc-76b883382f782f411cc529f126397e9fb99a0f45.tar.gz
* tree-dfa.c (add_referenced_var): Only global variables are
call-clobbered. * tree-flow.h (struct ptr_info_def): Add field pt_global_mem. * tree-ssa-alias.c (compute_points_to_and_addr_escape): Mark all pointers dereferenced if the statement dereferences them. (create_name_tags): Do not create memory tags for pointers that have PT_ANYTHING set. Also check if PT_VARS is not empty before creating a name tag. (compute_flow_sensitive_aliasing): Don't mark call-clobbered variables that share the same alias set with a pointer that may point anywhere. (add_may_alias): Add FIXME comment to remove clobbering aliased variables and tags. (replace_may_alias): Likewise. (set_pt_anything): Do not clear PT_VARS nor IS_DEREFERENCED. (merge_pointed_to_info): If the original variable has not points-to information, call set_pt_anything. (add_pointed_to_var): Do not prevent adding a pointed-to variable if the pointers is PT_ANYTHING. If the variable is a global, set PT_GLOBAL_MEM. (collect_points_to_info_r): Don't assume that PLUS_EXPRs of pointer type only come in PTR+OFFSET flavours. Always call merge_pointed_to_info on PHI arguments that are SSA_NAMEs. (get_nmt_for): Mark call-clobbered tags whose pointer points to global memory. * tree-ssa-operands.c (opf_kill_def, opf_no_vops): Switch values. (get_indirect_ref_operands): Always clear OPF_KILL_DEF from FLAGS. (add_stmt_operand): Abort if the caller tried to add a killing definition for a memory tag. * tree-ssa.c (verify_flow_sensitive_alias_info): Remove unnecessary checks. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@86198 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-dfa.c')
-rw-r--r--gcc/tree-dfa.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/tree-dfa.c b/gcc/tree-dfa.c
index 0273406df84..b8a9b03324f 100644
--- a/gcc/tree-dfa.c
+++ b/gcc/tree-dfa.c
@@ -903,10 +903,8 @@ add_referenced_var (tree var, struct walk_state *walk_state)
v_ann->uid = num_referenced_vars;
VARRAY_PUSH_TREE (referenced_vars, var);
- /* Initially assume that all memory variables are
- call-clobbered. This will be refined later by the alias
- analyzer. */
- if (needs_to_live_in_memory (var))
+ /* Global variables are always call-clobbered. */
+ if (is_global_var (var))
mark_call_clobbered (var);
/* If an initialized global variable then register the initializer