[flang] Fixed restrictions checking for OpenACC loop-associated constructs.
CheckDoConcurrentClauseRestriction and CheckTileClauseRestriction expect that the construct has associated DoConstruct, while it is not set when the do-loop has no loop control. The change is to skip the clauses checks, when the do-loop does not have the loop control. An alternative fix would be to associate the DoConstruct even when the do-loop has no loop control and let Check*ClauseRestriction run their checks, but I am not sure if associating invalid DoConstruct is a good idea. This fixes failure in Semantics/OpenACC/acc-canonicalization-validity.f90 reported in D142279. Reviewed By: clementval Differential Revision: https://reviews.llvm.org/D142652
Loading
Please sign in to comment