diff options
author | Toon Moene <toon@moene.indiv.nluug.nl> | 2006-03-21 07:32:57 +0100 |
---|---|---|
committer | Toon Moene <toon@gcc.gnu.org> | 2006-03-21 06:32:57 +0000 |
commit | 0698a1d2bd56fc3b12c1fe235b27030f5d8a54bf (patch) | |
tree | b8851b36230f472b3fa762bc25e4577aed644008 /gcc/tree-ssa-alias.c | |
parent | e67c25c7381536222d154228d16467320ea1fcf8 (diff) | |
download | gcc-0698a1d2bd56fc3b12c1fe235b27030f5d8a54bf.tar.gz |
options.c (gfc_init_options): Initialize flag_argument_noalias to 3.
2006-03-21 Toon Moene <toon@moene.indiv.nluug.nl>
* fortran/options.c (gfc_init_options): Initialize
flag_argument_noalias to 3.
* doc/invoke.texi: Document new flag -fargument-noalias-anything.
* tree-ssa-alias.c (may_alias_p): If flag_argument_noalias > 2,
argument pointers may not alias any other storage.
* common.opt: Define option -fargument-noalias-anything.
* tree-ssa-structalias.c (intra_create_variable_infos): Fortran
alias semantics is specified by flag_argument_noalias > 2.
From-SVN: r112243
Diffstat (limited to 'gcc/tree-ssa-alias.c')
-rw-r--r-- | gcc/tree-ssa-alias.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/tree-ssa-alias.c b/gcc/tree-ssa-alias.c index 8f8fbfa04b9..7b702f00765 100644 --- a/gcc/tree-ssa-alias.c +++ b/gcc/tree-ssa-alias.c @@ -1804,8 +1804,17 @@ may_alias_p (tree ptr, HOST_WIDE_INT mem_alias_set, alias_stats.simple_resolved++; return false; } - - /* If -fargument-noalias-global is >1, pointer arguments may + + /* If -fargument-noalias-global is > 2, pointer arguments may + not point to anything else. */ + if (flag_argument_noalias > 2 && TREE_CODE (ptr) == PARM_DECL) + { + alias_stats.alias_noalias++; + alias_stats.simple_resolved++; + return false; + } + + /* If -fargument-noalias-global is > 1, pointer arguments may not point to global variables. */ if (flag_argument_noalias > 1 && is_global_var (var) && TREE_CODE (ptr) == PARM_DECL) |