aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/i386/avx512f-vcvttss2usi-2.c
blob: 4d19104776b7f14e777dc00e299a090772c7366e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/* { dg-do run } */
/* { dg-options "-O2 -mavx512f" } */
/* { dg-require-effective-target avx512f } */

#include "avx512f-check.h"

static unsigned int
__attribute__((noinline, unused))
test (union128 s1)
{
  return _mm_cvttss_u32 (s1.x);
}

void static
avx512f_test (void)
{
  union128 s1;
  unsigned int d;
  unsigned int e;

  s1.x = _mm_set_ps (24.43, 68.346, 45.12, 90.97);
  d =  test (s1);
  e = (unsigned int)s1.a[0];

  if (e != d)
    abort ();
}