summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP/nvptx_data_sharing.cpp
diff options
context:
space:
mode:
authorGheorghe-Teodor Bercea <gheorghe-teod.bercea@ibm.com>2018-03-22 17:33:27 +0000
committerGheorghe-Teodor Bercea <gheorghe-teod.bercea@ibm.com>2018-03-22 17:33:27 +0000
commit36cdfad06236e1f3f348ab68b7ba8083337c81b3 (patch)
treeca4d947a09e8030e12e6bdb564f2de1e1f0acb2c /clang/test/OpenMP/nvptx_data_sharing.cpp
parentb3297ef05179e1fee616b97b1c65b58e4c7fef17 (diff)
downloadbcm5719-llvm-36cdfad06236e1f3f348ab68b7ba8083337c81b3.tar.gz
bcm5719-llvm-36cdfad06236e1f3f348ab68b7ba8083337c81b3.zip
[OpenMP][Clang] Add call to global data sharing stack initialization on the workers side
Summary: The workers also need to initialize the global stack. The call to the initialization function needs to happen after the kernel_init() function is called by the master. This ensures that the per-team data structures of the runtime have been initialized. Reviewers: ABataev, grokos, carlo.bertolli, caomhin Reviewed By: ABataev Subscribers: jholewinski, guansong, cfe-commits Differential Revision: https://reviews.llvm.org/D44749 llvm-svn: 328219
Diffstat (limited to 'clang/test/OpenMP/nvptx_data_sharing.cpp')
-rw-r--r--clang/test/OpenMP/nvptx_data_sharing.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/OpenMP/nvptx_data_sharing.cpp b/clang/test/OpenMP/nvptx_data_sharing.cpp
index 26ab3c0201b..68245c9abae 100644
--- a/clang/test/OpenMP/nvptx_data_sharing.cpp
+++ b/clang/test/OpenMP/nvptx_data_sharing.cpp
@@ -27,6 +27,11 @@ void test_ds(){
}
}
+/// ========= In the worker function ========= ///
+// CK1: {{.*}}define internal void @__omp_offloading{{.*}}test_ds{{.*}}_worker()
+// CK1: call void @llvm.nvvm.barrier0()
+// CK1: call void @__kmpc_data_sharing_init_stack
+
/// ========= In the kernel function ========= ///
// CK1: {{.*}}define void @__omp_offloading{{.*}}test_ds{{.*}}()
OpenPOWER on IntegriCloud