This is an archive of the discontinued LLVM Phabricator instance.

write semantics tests for CHANGE TEAM statement.
ClosedPublic

Authored by hussainjk on Nov 13 2022, 6:59 AM.

Details

Summary

Added semantics tests for aspects of CHANGE TEAM statements which are not duplicates from FORM TEAM statements.

Diff Detail

Event Timeline

hussainjk created this revision.Nov 13 2022, 6:59 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptNov 13 2022, 6:59 AM
hussainjk requested review of this revision.Nov 13 2022, 6:59 AM
ktras added a comment.Jan 4 2023, 10:19 AM

Thanks @hussainjk for these tests. Per my comment inline of change_team01c.f90, the branching that is specified by the standard was not tested. However, locally I began to work on adding the ability for flang to check whether branching occurs or not in a change-team-construct, and while doing so I began to add to my local copy of your test to check my implementation. As I know that your focus is no longer on testing, if you update this patch and remove lines 11-24 from that test, then I can approve this patch. I will then add to your tests checks for branching in the patch that I submit to add additional checks on change-team-construct in flang.

flang/test/Semantics/change_team01c.f90
12

Per the 2018 Fortran standard 11.2 "Branching can be caused by a GO TO statement, a computed GO TO statement, a CALL statement that has an alt-return-spec, or an input/output statement that has an END=, EOR=, or ERR= specifier." So these tests from lines 11-24 do not test the constraint C1110, which I believe you intended to test.

Addressing review comments.

ktras accepted this revision.Feb 6 2023, 11:13 AM

Thank you for making the requested changes.
LGTM.

This revision is now accepted and ready to land.Feb 6 2023, 11:13 AM

Modified some block labels to fix a new label name collision error.

This revision was automatically updated to reflect the committed changes.