[Openmp-commits] [openmp] 71041a8 - [OpenMP][libomptarget][Tests] fix failing test
Joachim Protze via Openmp-commits
openmp-commits at lists.llvm.org
Tue Nov 3 04:33:24 PST 2020
Author: Joachim Protze
Date: 2020-11-03T13:15:33+01:00
New Revision: 71041a8b6bc48f0173ab6b82625e307fa8ffe264
URL: https://github.com/llvm/llvm-project/commit/71041a8b6bc48f0173ab6b82625e307fa8ffe264
DIFF: https://github.com/llvm/llvm-project/commit/71041a8b6bc48f0173ab6b82625e307fa8ffe264.diff
LOG: [OpenMP][libomptarget][Tests] fix failing test
D88149 updated `omp_get_initial_device` behavior to conform with OpenMP 5.1.
omp_get_initial_device() == omp_get_num_devices()
Added:
Modified:
openmp/libomptarget/test/unified_shared_memory/api.c
Removed:
################################################################################
diff --git a/openmp/libomptarget/test/unified_shared_memory/api.c b/openmp/libomptarget/test/unified_shared_memory/api.c
index b0a71ad35801..a1c94c88d686 100644
--- a/openmp/libomptarget/test/unified_shared_memory/api.c
+++ b/openmp/libomptarget/test/unified_shared_memory/api.c
@@ -33,8 +33,10 @@ int main(int argc, char *argv[]) {
// that do not support requires.
__tgt_register_requires(8);
- // CHECK: Initial device: -10
+ // CHECK: Initial device: [[INITIAL_DEVICE:[0-9]+]]
printf("Initial device: %d\n", omp_get_initial_device());
+ // CHECK: Num devices: [[INITIAL_DEVICE]]
+ printf("Num devices: %d\n", omp_get_num_devices());
//
// Target alloc & target memcpy
More information about the Openmp-commits
mailing list