This is an archive of the discontinued LLVM Phabricator instance.

Fix crash when __kmp_task_team_setup called for single threaded team.
ClosedPublic

Authored by jlpeyton on Nov 16 2015, 2:14 PM.

Details

Summary

The task_team pointer is dereferenced unconditionally which causes a SEGFAULT when it is NULL (e.g. for serialized parallel, that can happen for "teams" construct or for "target nowait").
The solution is to skip second task team setup for single thread team.

Diff Detail

Repository
rL LLVM

Event Timeline

jlpeyton updated this revision to Diff 40340.Nov 16 2015, 2:14 PM
jlpeyton retitled this revision from to Fix crash when __kmp_task_team_setup called for single threaded team..
jlpeyton updated this object.
jlpeyton set the repository for this revision to rL LLVM.
jlpeyton added a subscriber: openmp-commits.
AndreyChurbanov accepted this revision.Nov 20 2015, 5:17 AM
AndreyChurbanov edited edge metadata.

LGTM

This revision is now accepted and ready to land.Nov 20 2015, 5:17 AM
This revision was automatically updated to reflect the committed changes.