]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/gcc.dg/tree-ssa/alias-access-path-12.c
Fix profile update in tree_transform_and_unroll_loop
[thirdparty/gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / alias-access-path-12.c
1 /* { dg-do compile } */
2 /* { dg-options "-O1 -fno-strict-aliasing -fdump-tree-optimized" } */
3
4 struct S
5 {
6 int i;
7 int j;
8 };
9 union U
10 {
11 struct S a[10];
12 };
13 int
14 foo (union U *u, int n, int i, int j)
15 {
16 u->a[i].i = 123;
17 u->a[j].j = j;
18 return u->a[i].i;
19 }
20 /* { dg-final { scan-tree-dump-times "return 123" 1 "optimized"} } */