summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP/target_codegen.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2017-11-28 21:11:44 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2017-11-28 21:11:44 +0000
commit2ba67045e337702b09ae3f97d6bd0c5f77a049a6 (patch)
treedc86bf197d848309f3d6ca21df5a5233e7966760 /clang/test/OpenMP/target_codegen.cpp
parent4e0b04300933c40c1d16ac97d9dacd705d2867be (diff)
downloadbcm5719-llvm-2ba67045e337702b09ae3f97d6bd0c5f77a049a6.tar.gz
bcm5719-llvm-2ba67045e337702b09ae3f97d6bd0c5f77a049a6.zip
[OPENMP] Generalize capturing of clauses expressions.
The handling and capturing of the non-constant expressions of some of the capturable clauses in combined directives is generalized. llvm-svn: 319227
Diffstat (limited to 'clang/test/OpenMP/target_codegen.cpp')
-rw-r--r--clang/test/OpenMP/target_codegen.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/clang/test/OpenMP/target_codegen.cpp b/clang/test/OpenMP/target_codegen.cpp
index 388a7ac3a3f..91a0b83e6d2 100644
--- a/clang/test/OpenMP/target_codegen.cpp
+++ b/clang/test/OpenMP/target_codegen.cpp
@@ -97,9 +97,7 @@ int foo(int n) {
static long *plocal;
// CHECK: [[ADD:%.+]] = add nsw i32
- // CHECK: store i32 [[ADD]], i32* [[CAPTURE:%.+]],
- // CHECK: [[LD:%.+]] = load i32, i32* [[CAPTURE]],
- // CHECK: [[DEVICE:%.+]] = sext i32 [[LD]] to i64
+ // CHECK: [[DEVICE:%.+]] = sext i32 [[ADD]] to i64
// CHECK: [[RET:%.+]] = call i32 @__tgt_target(i64 [[DEVICE]], i8* @{{[^,]+}}, i32 0, i8** null, i8** null, i[[SZ]]* null, i64* null)
// CHECK-NEXT: [[ERROR:%.+]] = icmp ne i32 [[RET]], 0
// CHECK-NEXT: br i1 [[ERROR]], label %[[FAIL:[^,]+]], label %[[END:[^,]+]]
@@ -111,10 +109,8 @@ int foo(int n) {
{
}
- // CHECK: [[ADD:%.+]] = add nsw i32
- // CHECK: store i32 [[ADD]], i32* [[CAPTURE:%.+]],
- // CHECK-DAG: [[LD:%.+]] = load i32, i32* [[CAPTURE]],
- // CHECK-DAG: [[DEVICE:%.+]] = sext i32 [[LD]] to i64
+ // CHECK-DAG: [[ADD:%.+]] = add nsw i32
+ // CHECK-DAG: [[DEVICE:%.+]] = sext i32 [[ADD]] to i64
// CHECK-DAG: [[RET:%.+]] = call i32 @__tgt_target(i64 [[DEVICE]], i8* @{{[^,]+}}, i32 2, i8** [[BPR:%[^,]+]], i8** [[PR:%[^,]+]], i[[SZ]]* getelementptr inbounds ([2 x i[[SZ]]], [2 x i[[SZ]]]* [[SIZET]], i32 0, i32 0), i64* getelementptr inbounds ([2 x i64], [2 x i64]* [[MAPT]], i32 0, i32 0)
// CHECK-DAG: [[BPR]] = getelementptr inbounds [2 x i8*], [2 x i8*]* [[BP:%[^,]+]], i32 0, i32 0
// CHECK-DAG: [[PR]] = getelementptr inbounds [2 x i8*], [2 x i8*]* [[P:%[^,]+]], i32 0, i32 0
OpenPOWER on IntegriCloud