summaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-26 21:02:43 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-26 21:02:43 +0000
commit5b449890e29d6438a144e0f583ae7560ca9ae174 (patch)
tree0c8731228fa873a40ebda7c821f6c84a41b9a12f /gcc/testsuite
parenta1ab46376685a6e38f8ba71c75dfd4c50d057f44 (diff)
downloadgcc-5b449890e29d6438a144e0f583ae7560ca9ae174.tar.gz
2006-02-26 Richard Guenther <rguenther@suse.de>
PR tree-optimization/26421 * tree-ssa-alias.c (find_used_portions): Don't treat parameters in function calls that are ADDR_EXPRs as using the whole structure. * gcc.dg/tree-ssa/pr26421.c: New testcase. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@111461 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/pr26421.c19
2 files changed, 24 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 68924f56938..81f9b5e7c1e 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2006-02-26 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/26421
+ * gcc.dg/tree-ssa/pr26421.c: New testcase.
+
2006-02-26 Steven Bosscher <stevenb.gcc@gmail.com>
* gcc.dg/20031201-1.c: Don't use -frerun-loop-opt.
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/pr26421.c b/gcc/testsuite/gcc.dg/tree-ssa/pr26421.c
new file mode 100644
index 00000000000..edb3685c11e
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/tree-ssa/pr26421.c
@@ -0,0 +1,19 @@
+/* { dg-do compile } */
+/* { dg-options "-O2 -fdump-tree-alias1-vops" } */
+
+typedef struct {
+ int i;
+ int j;
+ int k;
+} Foo;
+
+void bar(Foo*);
+void foo(void)
+{
+ Foo a;
+ a.i = 1;
+ bar(&a);
+}
+
+/* { dg-final { scan-tree-dump-times "V_MAY_DEF" 1 "alias1" } } */
+/* { dg-final { cleanup-tree-dump "alias1" } } */