summaryrefslogtreecommitdiff
path: root/test/OpenMP/cancel_codegen.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2016-11-25 19:07:40 +0000
committerDimitry Andric <dim@FreeBSD.org>2016-11-25 19:07:40 +0000
commit17c7957f023f02fc2c88f51f8908c19b52609275 (patch)
treec654618ff2d38e26916b49614d89fe01f4a4818d /test/OpenMP/cancel_codegen.cpp
parentc477790a57f44875b9de2043f2eb47dff2d20133 (diff)
Diffstat (limited to 'test/OpenMP/cancel_codegen.cpp')
-rw-r--r--test/OpenMP/cancel_codegen.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/OpenMP/cancel_codegen.cpp b/test/OpenMP/cancel_codegen.cpp
index 8234193e8f95..059a8d3901f4 100644
--- a/test/OpenMP/cancel_codegen.cpp
+++ b/test/OpenMP/cancel_codegen.cpp
@@ -91,9 +91,11 @@ for (int i = 0; i < argc; ++i) {
}
}
// CHECK: call void (%ident_t*, i32, void (i32*, i32*, ...)*, ...) @__kmpc_fork_call(
-#pragma omp parallel for
+int r = 0;
+#pragma omp parallel for reduction(+:r)
for (int i = 0; i < argc; ++i) {
#pragma omp cancel for
+ r += i;
}
// CHECK: call void (%ident_t*, i32, void (i32*, i32*, ...)*, ...) @__kmpc_fork_call(
return argc;
@@ -164,6 +166,9 @@ for (int i = 0; i < argc; ++i) {
// CHECK: [[CONTINUE]]
// CHECK: br label
// CHECK: call void @__kmpc_for_static_fini(
+// CHECK: call i32 @__kmpc_reduce_nowait(
+// CHECK: call void @__kmpc_end_reduce_nowait(
+// CHECK: call void @__kmpc_for_static_fini(
// CHECK: ret void
#endif