comparison gcc/testsuite/gcc.dg/pr80286.c @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
comparison
equal deleted inserted replaced
68:561a7518be6b 111:04ced10e8804
1 /* PR target/80286 */
2 /* { dg-do run } */
3 /* { dg-options "-O2 -Wno-psabi" } */
4
5 typedef int V __attribute__((vector_size (4 * sizeof (int))));
6
7 __attribute__((noinline, noclone)) V
8 foo (V x, V y)
9 {
10 return x << y[0];
11 }
12
13 int
14 main ()
15 {
16 V x = { 1, 2, 3, 4 };
17 V y = { 5, 6, 7, 8 };
18 V z = foo (x, y);
19 V e = { 1 << 5, 2 << 5, 3 << 5, 4 << 5 };
20 if (__builtin_memcmp (&z, &e, sizeof (V)))
21 __builtin_abort ();
22 return 0;
23 }