[RISCV][FMV] Support target_clones (#85786)
[llvm-project.git] / clang / test / AST / ast-print-openacc-loop-construct.cpp
blobcde302a66f3af7586f81f074bf884ee840556eca
1 // RUN: %clang_cc1 -fopenacc -Wno-openacc-deprecated-clause-alias -ast-print %s -o - | FileCheck %s
3 struct SomeStruct{};
5 void foo() {
6 // CHECK: #pragma acc loop
7 // CHECK-NEXT: for (;;)
8 // CHECK-NEXT: ;
9 #pragma acc loop
10 for(;;);
12 // CHECK: #pragma acc loop device_type(SomeStruct)
13 // CHECK-NEXT: for (;;)
14 // CHECK-NEXT: ;
15 #pragma acc loop device_type(SomeStruct)
16 for(;;);
18 // CHECK: #pragma acc loop device_type(int)
19 // CHECK-NEXT: for (;;)
20 // CHECK-NEXT: ;
21 #pragma acc loop device_type(int)
22 for(;;);
24 // CHECK: #pragma acc loop dtype(bool)
25 // CHECK-NEXT: for (;;)
26 // CHECK-NEXT: ;
27 #pragma acc loop dtype(bool)
28 for(;;);
30 // CHECK: #pragma acc loop dtype(AnotherIdent)
31 // CHECK-NEXT: for (;;)
32 // CHECK-NEXT: ;
33 #pragma acc loop dtype(AnotherIdent)
34 for(;;);
36 // CHECK: #pragma acc loop independent
37 // CHECK-NEXT: for (;;)
38 // CHECK-NEXT: ;
39 #pragma acc loop independent
40 for(;;);
41 // CHECK: #pragma acc loop seq
42 // CHECK-NEXT: for (;;)
43 // CHECK-NEXT: ;
44 #pragma acc loop seq
45 for(;;);
46 // CHECK: #pragma acc loop auto
47 // CHECK-NEXT: for (;;)
48 // CHECK-NEXT: ;
49 #pragma acc loop auto
50 for(;;);
52 int i;
53 float array[5];
55 // CHECK: #pragma acc loop private(i, array[1], array, array[1:2])
56 // CHECK-NEXT: for (;;)
57 // CHECK-NEXT: ;
58 #pragma acc loop private(i, array[1], array, array[1:2])
59 for(;;);