[PATCH] D123828: [mlir][OpenMP] Add omp.cancel and omp.cancellationpoint.
Kiran Chandramohan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 15 02:47:44 PDT 2022
kiranchandramohan requested changes to this revision.
kiranchandramohan added inline comments.
This revision now requires changes to proceed.
================
Comment at: flang/lib/Semantics/check-omp-structure.cpp:1808
CHECK_SIMPLE_CLAUSE(Compare, OMPC_compare)
+CHECK_SIMPLE_CLAUSE(CancelConstruct, OMPC_cancel_construct)
----------------
On a first look, it looks like we have a construct here instead of a clause. Would `CancelConstructType` be a better name?
================
Comment at: mlir/test/Dialect/OpenMP/ops.mlir:1014-1037
+func @omp_cancel(%if_cond : i1) -> () {
+ // Test with optional operand; if_expr.
+ // CHECK: omp.cancel cancel_construct(parallel) if(%{{.*}})
+ omp.cancel cancel_construct(parallel) if(%if_cond)
+ // CHECK: omp.cancel cancel_construct(loop)
+ omp.cancel cancel_construct(loop)
+ // CHECK: omp.cancel cancel_construct(sections)
----------------
There are a few restrictions regarding closely nested constructs. Some of the above might not be valid usage. Could you try implementing them?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D123828/new/
https://reviews.llvm.org/D123828
More information about the llvm-commits
mailing list