File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -4624,9 +4624,11 @@ void OmpStructureChecker::CheckWorkshareBlockStmts(
46244624void OmpStructureChecker::CheckWorkdistributeBlockStmts (
46254625 const parser::Block &block, parser::CharBlock source) {
46264626 unsigned version{context_.langOptions ().OpenMPVersion };
4627- if (version < 60 )
4627+ unsigned since{60 };
4628+ if (version < since)
46284629 context_.Say (source,
4629- " WORKDISTRIBUTE construct is only supported from openMP 6.0" _err_en_US);
4630+ " WORKDISTRIBUTE construct is not allowed in %s, %s" _err_en_US,
4631+ ThisVersion (version), TryVersion (since));
46304632
46314633 OmpWorkdistributeBlockChecker ompWorkdistributeBlockChecker{context_, source};
46324634
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ subroutine teams_workdistribute()
88 real (kind= real32) :: a
99 real (kind= real32), dimension (10 ) :: x
1010 real (kind= real32), dimension (10 ) :: y
11- ! ERROR: WORKDISTRIBUTE construct is only supported from openMP 6.0
11+ ! ERROR: WORKDISTRIBUTE construct is not allowed in OpenMP v5.0, try -fopenmp-version=60
1212 ! $omp teams workdistribute
1313 y = a * x + y
1414 ! $omp end teams workdistribute
You can’t perform that action at this time.
0 commit comments