This is an archive of the discontinued LLVM Phabricator instance.

[OpenMP] Fix handling of clause on wrong directive
ClosedPublic

Authored by jdenny on Jan 8 2018, 3:45 PM.

Details

Summary

First, this patch fixes an assert failure when, for example, "omp for"
has num_teams.

Second, this patch prevents duplicate diagnostics when, for example,
"omp for" has uniform.

This patch makes the general assumption (even where it doesn't
necessarily fix an existing bug) that it is worthless to perform sema
for a clause that appears on a directive on which OpenMP does not
permit that clause. However, due to this assumption, this patch
suppresses some diagnostics that were expected in the test suite. I
assert that those diagnostics were likely just distracting to the
user.

Diff Detail

Repository
rL LLVM

Event Timeline

jdenny created this revision.Jan 8 2018, 3:45 PM
This revision is now accepted and ready to land.Jan 9 2018, 10:46 AM

Alexey: Thanks for accepting. I do not have commit privileges. Would
you please commit for me?

Alexey: Thanks for accepting. I do not have commit privileges. Would
you please commit for me?

Sure

This revision was automatically updated to reflect the committed changes.