gcc/testsuite/gcc.dg/pr82190.c
raw| 1 | /* PR target/82190 */ |
| 2 | /* { dg-do run } */ |
| 3 | /* { dg-options "-O2 -fno-optimize-strlen -fweb" } */ |
| 4 | |
| 5 | char src[64] __attribute__ ((aligned)) = "aaaaaaa"; |
| 6 | char dst[64] __attribute__ ((aligned)); |
| 7 | |
| 8 | int |
| 9 | main () |
| 10 | { |
| 11 | __builtin_memcpy (dst, src, 6); |
| 12 | if (__builtin_memcmp (dst, src, 6)) |
| 13 | __builtin_abort (); |
| 14 | |
| 15 | __builtin_memcpy (dst, src, 7); |
| 16 | if (__builtin_memcmp (dst, src, 7)) |
| 17 | __builtin_abort (); |
| 18 | |
| 19 | return 0; |
| 20 | } |
| 21 | |
| 22 |