1 // FIXME: XFAIL the test because it is expected to return non-zero value.
3 // REQUIRES: x86-target-arch
4 // RUN: %clang_builtins %s %librt -o %t && %run %t
5 // REQUIRES: librt_has_cpu_model
6 //===-- cpu_model_test.c - Test __builtin_cpu_supports --------------------===//
8 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
9 // See https://llvm.org/LICENSE.txt for license information.
10 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
12 //===----------------------------------------------------------------------===//
14 // This file tests __builtin_cpu_supports for the compiler_rt library.
16 //===----------------------------------------------------------------------===//
21 #if defined(i386) || defined(__x86_64__)
22 if(__builtin_cpu_supports("avx2"))