aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/i386/avx512f-broadcast-gpr-2.c
blob: 91665b299adfd53e0fcadcc457170e423a59cf48 (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
28
29
/* { dg-do run } */
/* { dg-options "-mavx512f -O2" } */
/* { dg-require-effective-target avx512f } */

#include "avx512f-check.h"
#include "avx512f-broadcast-gpr-1.c"

void
avx512f_test (void)
{
  union512i_q q;
  union512i_d d;
  int i;

  q.x = foo_1 (3);
  d.x = foo_2 (5);

  for (i = 0; i < 8; i++)
  {
    if (q.a[i] != 3)
      abort ();
  }

  for (i = 0; i < 16; i++)
  {
    if (d.a[i] != 5)
      abort ();
  }
}