summaryrefslogtreecommitdiff
path: root/test/OpenMP
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
commit5bee51df6c768e513de5b42635cbf98714bccfe6 (patch)
tree5393f01aec1fd3638e0c6351d88b5af2712316af /test/OpenMP
parent09533252592d1d8aea1873ac8cda674439c2e9e1 (diff)
[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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319227 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/OpenMP')
-rw-r--r--test/OpenMP/target_codegen.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/test/OpenMP/target_codegen.cpp b/test/OpenMP/target_codegen.cpp
index 388a7ac3a3..91a0b83e6d 100644
--- a/test/OpenMP/target_codegen.cpp
+++ b/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