1 /* { dg-do compile } */
2 /* { dg-options "-O -fstrict-aliasing -fdump-tree-optimized" } */
4 struct S { float f; int i; };
5 struct R { int x; int i; };
7 /* Strict-aliasing rules say that int and float do not alias. */
8 int bar(struct S *s, int *i)
15 /* Strict-aliasing rules say that S and R do not alias. */
16 int foo(struct S *s, struct R *r)
23 /* { dg-final { scan-tree-dump-times "return 0;" 2 "optimized" } } */
24 /* { dg-final { cleanup-tree-dump "optimized" } } */