i386: Adjust rtx cost for imulq and imulw [PR115749]
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / vect-early-break-template_1.c
blobacc088282ad0b82574d43251942e5cbba630c295
1 #include "tree-vect.h"
3 #ifndef N
4 #define N 803
5 #endif
7 #ifndef P
8 #define P 0
9 #endif
11 unsigned vect_a[N] = {0};
12 unsigned vect_b[N] = {0};
14 __attribute__((noipa, noinline))
15 unsigned test4(unsigned x)
17 unsigned ret = 0;
18 for (int i = 0; i < N; i++)
20 vect_b[i] = x + i;
21 if (vect_a[i] > x)
22 break;
23 vect_a[i] = x;
26 return ret;
29 extern void abort ();
31 int main ()
33 check_vect ();
35 int x = 1;
36 int idx = P;
37 vect_a[idx] = x + 1;
39 test4(x);
41 if (vect_b[idx] != (x + idx))
42 abort ();
44 if (vect_a[idx] != x + 1)
45 abort ();
47 if (idx > 0 && vect_a[idx-1] != x)
48 abort ();