summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/bmi-6.c
blob: a4489e0b5a697e0e9e5b96e9cb49208ab37f7476 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* { dg-do link } */
/* { dg-options "-O2 -mbmi" } */

#include <x86intrin.h>

/* Test that a constant operand 0 to tzcnt gets folded.  */
extern void link_error(void);
int main()
{
  if (__tzcnt_u16(0) != 16)
    link_error();
  return 0;
}