Files
clang-p2996/openmp/libomptarget/test/api/omp_get_num_procs.c
Joseph Huber 8a181f43da [OpenMP][Obvious] Fix incompatbile function prototype causing failures
Summary:
This function needs `void` as the arguments to be ABI compatbile with
what is actually defined. This is enforced when doing CUDA separable
linking of the runtime.
2023-10-25 10:44:07 -05:00

16 lines
276 B
C

// RUN: %libomptarget-compile-run-and-check-generic
#include <stdio.h>
int omp_get_num_procs(void);
int main() {
int num_procs;
#pragma omp target map(from : num_procs)
{ num_procs = omp_get_num_procs(); }
// CHECK: PASS
if (num_procs > 0)
printf("PASS\n");
}