diff --git a/openmp/libomptarget/DeviceRTL/src/exports b/openmp/libomptarget/DeviceRTL/src/exports --- a/openmp/libomptarget/DeviceRTL/src/exports +++ b/openmp/libomptarget/DeviceRTL/src/exports @@ -4,3 +4,4 @@ memcmp printf +__assert_fail diff --git a/openmp/libomptarget/test/api/assert.c b/openmp/libomptarget/test/api/assert.c new file mode 100644 --- /dev/null +++ b/openmp/libomptarget/test/api/assert.c @@ -0,0 +1,14 @@ +// RUN: %libomptarget-compile-run-and-check-generic + +#include +#include + +int main() { + int i = 1; +#pragma omp target + assert(i > 0); + + // CHECK: PASS + printf("PASS\n"); + return 0; +}