Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / OpenMP / declare_variant_bind_to_decl.cpp
blobdca18abb36c896d947acf8107746181b1b171c33
1 // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs
2 // RUN: %clang_cc1 -verify -fopenmp -x c++ -triple powerpc64le-unknown-unknown -emit-llvm %s -o - | FileCheck %s
3 // expected-no-diagnostics
5 #ifndef HEADER
6 #define HEADER
8 void foo() { }
10 #pragma omp begin declare variant match( \
11 device = {arch(ppc64le, ppc64)}, \
12 implementation = {extension(match_any, bind_to_declaration)})
14 void foo();
16 #pragma omp end declare variant
18 int main() {
19 foo();
22 #endif
23 // CHECK-LABEL: define {{[^@]+}}@_Z3foov
24 // CHECK-SAME: () #[[ATTR0:[0-9]+]] {
25 // CHECK-NEXT: entry:
26 // CHECK-NEXT: ret void
29 // CHECK-LABEL: define {{[^@]+}}@main
30 // CHECK-SAME: () #[[ATTR1:[0-9]+]] {
31 // CHECK-NEXT: entry:
32 // CHECK-NEXT: call void @"_Z74foo$ompvariant$S2$s7$Pppc64le$Pppc64$S3$s9$Pmatch_any$Pbind_to_declarationv"()
33 // CHECK-NEXT: ret i32 0