summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP/single_codegen.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2018-10-05 15:08:53 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2018-10-05 15:08:53 +0000
commitfd006c44eeffe1f018f7fda13eacb67a6606ec9c (patch)
treef109d0337a0888e5048c30920ed8e1cec54a72bd /clang/test/OpenMP/single_codegen.cpp
parent00216bca66242fadfd22165d4efd1479d1d2ae82 (diff)
downloadbcm5719-llvm-fd006c44eeffe1f018f7fda13eacb67a6606ec9c.tar.gz
bcm5719-llvm-fd006c44eeffe1f018f7fda13eacb67a6606ec9c.zip
[OPENMP] Fix emission of the __kmpc_global_thread_num.
Fixed emission of the __kmpc_global_thread_num() so that it is not messed up with alloca instructions anymore. Plus, fixes emission of the __kmpc_global_thread_num() functions in the target outlined regions so that they are not called before runtime is initialized. llvm-svn: 343856
Diffstat (limited to 'clang/test/OpenMP/single_codegen.cpp')
-rw-r--r--clang/test/OpenMP/single_codegen.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/test/OpenMP/single_codegen.cpp b/clang/test/OpenMP/single_codegen.cpp
index a5426bf483e..df5b2ca0e67 100644
--- a/clang/test/OpenMP/single_codegen.cpp
+++ b/clang/test/OpenMP/single_codegen.cpp
@@ -74,9 +74,12 @@ struct SST {
// CHECK-LABEL: @main
// TERM_DEBUG-LABEL: @main
int main() {
+ // CHECK: alloca i32
// CHECK-DAG: [[A_ADDR:%.+]] = alloca i8
// CHECK-DAG: [[A2_ADDR:%.+]] = alloca [2 x i8]
// CHECK-DAG: [[C_ADDR:%.+]] = alloca [[TEST_CLASS_TY]]
+ // CHECK-DAG: [[DID_IT:%.+]] = alloca i32,
+ // CHECK-DAG: [[COPY_LIST:%.+]] = alloca [5 x i8*],
char a;
char a2[2];
TestClass &c = tc;
@@ -84,9 +87,6 @@ int main() {
SS ss(c.a);
// CHECK: [[GTID:%.+]] = call i32 @__kmpc_global_thread_num([[IDENT_T_TY]]* [[DEFAULT_LOC:@.+]])
-// CHECK-DAG: [[DID_IT:%.+]] = alloca i32,
-// CHECK-DAG: [[COPY_LIST:%.+]] = alloca [5 x i8*],
-
// CHECK: [[RES:%.+]] = call i32 @__kmpc_single([[IDENT_T_TY]]* [[DEFAULT_LOC]], i32 [[GTID]])
// CHECK-NEXT: [[IS_SINGLE:%.+]] = icmp ne i32 [[RES]], 0
// CHECK-NEXT: br i1 [[IS_SINGLE]], label {{%?}}[[THEN:.+]], label {{%?}}[[EXIT:.+]]
OpenPOWER on IntegriCloud