i386: Adjust rtx cost for imulq and imulw [PR115749]
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / pr65206.c
blob3b6262622c00e38655c55fda683a8daf1b6d27aa
1 /* { dg-do compile } */
2 /* { dg-require-effective-target vect_double } */
3 /* { dg-additional-options "-fno-trapping-math -fno-allow-store-data-races" } */
4 /* { dg-additional-options "-mavx" { target avx } } */
6 #define N 1024
8 double a[N], b[N];
10 void foo ()
12 for (int i = 0; i < N; ++i)
13 if (b[i] < 3.)
14 a[i] += b[i];
17 /* We get a .MASK_STORE because while the load of a[i] does not trap
18 the store would introduce store data races. Make sure we still
19 can handle the data dependence with zero distance. */
21 /* { dg-final { scan-tree-dump-not "versioning for alias required" "vect" { target { vect_masked_store || avx } } } } */
22 /* { dg-final { scan-tree-dump "vectorized 1 loops in function" "vect" { target { vect_masked_store || avx } } } } */