Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update parallel.h #55

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Update parallel.h #55

wants to merge 1 commit into from

Conversation

lanvent
Copy link

@lanvent lanvent commented Sep 3, 2020

No description provided.

@tomtseng
Copy link
Member

tomtseng commented Sep 3, 2020

@ldhulipala are you familiar enough with OpenMP to comment on this? This change looks correct -- without it, I think left() and right() run sequentially. But maybe it's better to have --- instead of having the current thread spawn a task for left() + spawn a task for right() --- the current thread spawn a task only for left() and to run right() itself before waiting. The other logic in pardo() for OpenMP also looks suspicious to me. If someone runs a par_do in a parallel_for, does the bool in_par_do logic get messed up? And it seems bad to have nested pardos not taskwait since our assumption when programming is that after a pardo, both left() and right() have completed.

@tomtseng tomtseng requested a review from ldhulipala September 3, 2020 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants