diff options
author | Daniel Berlin <dberlin@dberlin.org> | 2005-09-29 19:38:00 +0000 |
---|---|---|
committer | Daniel Berlin <dberlin@gcc.gnu.org> | 2005-09-29 19:38:00 +0000 |
commit | 8d2c775f0175a71fefe00156505c9f5c50af4114 (patch) | |
tree | bb0627ae5f2c63a515449ff199a6679ce0a7e52b /gcc/tree-ssa-structalias.c | |
parent | ffc53fb0fa533d427c814b3a00da426ce25e7003 (diff) | |
download | gcc-8d2c775f0175a71fefe00156505c9f5c50af4114.zip gcc-8d2c775f0175a71fefe00156505c9f5c50af4114.tar.gz gcc-8d2c775f0175a71fefe00156505c9f5c50af4114.tar.bz2 |
re PR tree-optimization/24117 (struct is not marked fully as call clobbered)
2005-09-29 Daniel Berlin <dberlin@dberlin.org>
Fix PR tree-optimization/24117
* tree-ssa-structalias.c (find_func_aliases): Strip nops
before considering whether to use anyoffset.
From-SVN: r104791
Diffstat (limited to 'gcc/tree-ssa-structalias.c')
-rw-r--r-- | gcc/tree-ssa-structalias.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/tree-ssa-structalias.c b/gcc/tree-ssa-structalias.c index c41519c..890006a 100644 --- a/gcc/tree-ssa-structalias.c +++ b/gcc/tree-ssa-structalias.c @@ -2817,16 +2817,18 @@ find_func_aliases (tree t, struct alias_info *ai) case tcc_expression: case tcc_unary: { + tree anyoffsetrhs = rhsop; bool need_anyoffset = false; rhs = get_constraint_for (rhsop, &need_anyoffset); process_constraint (new_constraint (lhs, rhs)); - + + STRIP_NOPS (anyoffsetrhs); /* When taking the address of an aggregate type, from the LHS we can access any field of the RHS. */ if (need_anyoffset || (rhs.type == ADDRESSOF && !(get_varinfo (rhs.var)->is_special_var) - && AGGREGATE_TYPE_P (TREE_TYPE (TREE_TYPE (rhsop))))) + && AGGREGATE_TYPE_P (TREE_TYPE (TREE_TYPE (anyoffsetrhs))))) { rhs.var = anyoffset_id; rhs.type = ADDRESSOF; |