1 /* { dg-do run } */ 2 /* { dg-require-effective-target avx } */ 3 /* { dg-options "-O2 -mavx" } */ 4 5 #include "avx-check.h" 6 7 void static avx_test(void)8avx_test (void) 9 { 10 int i; 11 int d; 12 union256 s1; 13 float source[8] = {-45, -3, -34.56, 35, 5.46,46, -464.3, 56}; 14 int e = 0; 15 16 s1.x = _mm256_loadu_ps (source); 17 d = _mm256_movemask_ps (s1.x); 18 19 for (i = 0; i < 8; i++) 20 if (source[i] < 0) 21 e |= (1 << i); 22 23 if (checkVi (&d, &e, 1)) 24 abort (); 25 } 26