LLVM OpenMP
runtime
test
env
omp_default_device_all_rejected.c
Go to the documentation of this file.
1
// RUN: %libomp-compile
2
// RUN: env KMP_WARNINGS=1 OMP_DEFAULT_DEVICE_ALL=2 %libomp-run 2>&1 \
3
// RUN: | FileCheck %s
4
//
5
// Suffix on global-scope base must be rejected with a warning AND not
6
// reach the ICV.
7
8
#include <omp.h>
9
#include <stdio.h>
10
11
int
main
(
void
) {
12
(
void
)
omp_get_max_threads
();
13
int
dd = omp_get_default_device();
14
if
(dd == 2) {
15
fprintf(stderr,
"FAIL: OMP_DEFAULT_DEVICE_ALL=2 was applied; got %d\n"
, dd);
16
return
1;
17
}
18
printf(
"DONE\n"
);
19
return
0;
20
}
21
22
// CHECK: {{^OMP: Warning #[0-9]+:.*OMP_DEFAULT_DEVICE_ALL.*}}
23
// CHECK: DONE
void
void
Definition
ittnotify.h:3324
main
int main(void)
Definition
omp_default_device_all_rejected.c:11
omp_get_max_threads
int omp_get_max_threads()
Generated on
for LLVM OpenMP by
1.14.0