LLVM OpenMP 20.0.0git
|
Go to the source code of this file.
Functions | |
kmp_int32 | __kmpc_cancel (ident_t *loc_ref, kmp_int32 gtid, kmp_int32 cncl_kind) |
kmp_int32 | __kmpc_cancellationpoint (ident_t *loc_ref, kmp_int32 gtid, kmp_int32 cncl_kind) |
kmp_int32 | __kmpc_cancel_barrier (ident_t *loc, kmp_int32 gtid) |
int | __kmp_get_cancellation_status (int cancel_kind) |
loc_ref | location of the original task directive |
gtid | Global thread ID of encountering thread |
Query function to query the current status of cancellation requests. Can be used to implement the following pattern:
if (kmp_get_cancellation_status(kmp_cancel_parallel)) { perform_cleanup(); #pragma omp cancellation point parallel }
Definition at line 309 of file kmp_cancel.cpp.
References __kmp_entry_thread(), __kmp_omp_cancellation, cancel_loop, cancel_parallel, kmp_taskgroup::cancel_request, cancel_sections, cancel_taskgroup, kmp_team::t, and task::th.
Referenced by FTN_GET_CANCELLATION_STATUS().
loc_ref | location of the original task directive |
gtid | Global thread ID of encountering thread |
cncl_kind | Cancellation kind (parallel, for, sections, taskgroup) |
Request cancellation of the binding OpenMP region.
Definition at line 29 of file kmp_cancel.cpp.
References __kmp_get_gtid, __kmp_omp_cancellation, __kmp_threads, __ompt_get_task_info_internal(), cancel_loop, cancel_noreq, cancel_parallel, kmp_taskgroup::cancel_request, cancel_sections, cancel_taskgroup, KC_TRACE, KMP_ASSERT, KMP_DEBUG_ASSERT, ompt_callbacks, ompt_enabled, OMPT_GET_RETURN_ADDRESS, kmp_team::t, task::th, and type.
loc_ref | location of the original task directive |
gtid | Global thread ID of encountering thread |
Barrier with cancellation point to send threads from the barrier to the end of the parallel region. Needs a special code pattern as documented in the design document for the cancellation feature.
Definition at line 243 of file kmp_cancel.cpp.
References __kmp_get_gtid, __kmp_omp_cancellation, __kmp_threads, __kmpc_barrier(), cancel_loop, cancel_noreq, cancel_parallel, cancel_sections, cancel_taskgroup, KMP_ASSERT, KMP_ATOMIC_LD_RLX, KMP_DEBUG_ASSERT, loc, ret, and kmp_team::t.
loc_ref | location of the original task directive |
gtid | Global thread ID of encountering thread |
cncl_kind | Cancellation kind (parallel, for, sections, taskgroup) |
Cancellation point for the encountering thread.
Definition at line 135 of file kmp_cancel.cpp.
References __kmp_get_gtid, __kmp_omp_cancellation, __kmp_threads, __ompt_get_task_info_internal(), cancel_loop, cancel_noreq, cancel_parallel, kmp_taskgroup::cancel_request, cancel_sections, cancel_taskgroup, KC_TRACE, KMP_ASSERT, KMP_DEBUG_ASSERT, ompt_callbacks, ompt_enabled, OMPT_GET_RETURN_ADDRESS, kmp_team::t, task::th, and type.