gcc/testsuite/gcc.target/i386/memcpy-strategy-4.c
raw| 1 | /* PR target/64200 */ |
| 2 | /* { dg-do compile } */ |
| 3 | /* { dg-options "-O2 -march=atom -mmemcpy-strategy=libcall:-1:align -minline-stringops-dynamically" } */ |
| 4 | |
| 5 | #include <stdarg.h> |
| 6 | |
| 7 | extern void bar(char *x); |
| 8 | |
| 9 | void foo (int size, ...) |
| 10 | { |
| 11 | struct |
| 12 | { |
| 13 | char x[size]; |
| 14 | } d; |
| 15 | |
| 16 | va_list ap; |
| 17 | va_start(ap, size); |
| 18 | d = va_arg(ap, typeof (d)); |
| 19 | va_end(ap); |
| 20 | bar(d.x); |
| 21 | } |