2009-07-17 Richard Guenther <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.dg / torture / 20090618-1.c
blob8b601d62c79d2ccbf815077405e5b5bb43b494b8
1 /* { dg-do run } */
2 /* { dg-skip-if "" { *-*-* } { "-O0" } { "" } } */
4 extern void abort (void);
6 struct X { int *p; int *q; };
8 int foo(void)
10 int i = 0, j = 1;
11 struct X x, y;
12 int **p;
13 y.p = &i;
14 x.q = &j;
15 p = __builtin_mempcpy (&x, &y, sizeof (int *));
16 return **p;
19 int main()
21 if (foo() != 1)
22 abort ();
23 return 0;