summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/bmi-5.c
blob: 906bf217cc1dbe52b98f47dbdf9831c5ec766398 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* { dg-do link } */
/* { dg-require-effective-target lp64 } */
/* { 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_u64(0) != 64)
    link_error();
  return 0;
}