This is an archive of the discontinued LLVM Phabricator instance.

[flang][OpenMP] Add parser support for Requires directive
ClosedPublic

Authored by skatrak on Oct 27 2022, 10:21 AM.

Details

Summary

OpenMP 5.0 adds support for the "requires" directive. This patch adds parser support for it in flang.

Diff Detail

Event Timeline

skatrak created this revision.Oct 27 2022, 10:21 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald Transcript
skatrak requested review of this revision.Oct 27 2022, 10:21 AM
dpalermo requested changes to this revision.Nov 2 2022, 2:57 PM
dpalermo added inline comments.
flang/lib/Parser/openmp-parsers.cpp
295–305

These should probably be ordered alphabetically with the other clauses to match the existing code.

This revision now requires changes to proceed.Nov 2 2022, 2:57 PM
skatrak updated this revision to Diff 472937.Nov 3 2022, 7:41 AM

Reorder clauses

skatrak marked an inline comment as done.
kiranchandramohan requested changes to this revision.Nov 3 2022, 8:40 AM

Please add an fdebug-unparse and an fdebug-dump-parse-tree test.

This revision now requires changes to proceed.Nov 3 2022, 8:40 AM
dpalermo accepted this revision.Nov 3 2022, 8:41 AM
skatrak updated this revision to Diff 474215.Nov 9 2022, 3:27 AM
  • Add further unit tests
kiranchandramohan accepted this revision.Nov 9 2022, 2:40 PM

Thanks for adding the test. LGTM.

This revision is now accepted and ready to land.Nov 9 2022, 2:40 PM
This revision was automatically updated to reflect the committed changes.