Skip to content

Commit

Permalink
Fix for crash in task dependencies
Browse files Browse the repository at this point in the history
With single thread using __kmpc_omp_wait_deps segfaults in OpenMP runtime.
Offloading with depend also encounters this problem when we generate
kmpc_omp_wait_deps instead of kmpc_omp_task_with_deps.

Patch by Alex Duran

Differential Revision: http://reviews.llvm.org/D21384

llvm-svn: 272949
  • Loading branch information
jpeyton52 committed Jun 16, 2016
1 parent fd6ad5b commit c505ab6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion openmp/runtime/src/kmp_taskdeps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ __kmpc_omp_wait_deps ( ident_t *loc_ref, kmp_int32 gtid, kmp_int32 ndeps, kmp_de
// - if the dephash is not yet created it means we have nothing to wait for
bool ignore = current_task->td_flags.team_serial || current_task->td_flags.tasking_ser || current_task->td_flags.final;
#if OMP_45_ENABLED
ignore = ignore && thread->th.th_task_team->tt.tt_found_proxy_tasks == FALSE;
ignore = ignore && thread->th.th_task_team != NULL && thread->th.th_task_team->tt.tt_found_proxy_tasks == FALSE;
#endif
ignore = ignore || current_task->td_dephash == NULL;

Expand Down

0 comments on commit c505ab6

Please sign in to comment.