From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 6B3D23858D3C; Wed, 16 Aug 2023 15:37:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6B3D23858D3C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1692200249; bh=3dSTtFM+Kx3DsdT5y9TMbaMePaHaFMBe3XfErUeNWTI=; h=From:To:Subject:Date:In-Reply-To:References:From; b=n7aGHz/mvIOyGGRskiQfdWQ8Wz1KYQ12ITjasEwK/5gfnM/Q2JrITsznNOyOTCgJ6 zFwrYx5/JBhflEV/mOi/7V1px/Bl+vEhlX5z9qZ40qk3XN7ZEDxP4i6MaTfLycX6up RKSMvvuyC0dXxojQ/n8WRVogZP1s1G1MDEmbYRkk= From: "marshall.ward at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/101602] [F2018] local and local_init are not supported in DO CONCURRENT Date: Wed, 16 Aug 2023 15:37:28 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 11.1.0 X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: marshall.ward at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P4 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D101602 --- Comment #4 from Marshall Ward --- Thank you Michael, that is very informative, particularly with respect to LOCAL_INIT vs FIRSTPRIVATE. If we could just get support for LOCAL, then we may be to start using do-concurrent in our production codes. Perhaps there= is a possibility of only adding support for LOCAL and SHARED, and raising an e= rror if LOCAL_INIT appears? I have no experience with the GCC source, but I can see where this should appear in the parser: diff --git a/gcc/fortran/match.cc b/gcc/fortran/match.cc index ba23bcd9692..439839295a1 100644 --- a/gcc/fortran/match.cc +++ b/gcc/fortran/match.cc @@ -2642,36 +2642,38 @@ gfc_match_do (void) if (gfc_match (" concurrent") =3D=3D MATCH_YES) { gfc_forall_iterator *head; gfc_expr *mask; if (!gfc_notify_std (GFC_STD_F2008, "DO CONCURRENT construct at %C")) return MATCH_ERROR; mask =3D NULL; head =3D NULL; m =3D match_forall_header (&head, &mask); if (m =3D=3D MATCH_NO) return m; if (m =3D=3D MATCH_ERROR) goto concurr_cleanup; + /* TODO: Parse local, local_init, shared */ + if (gfc_match_eos () !=3D MATCH_YES) goto concurr_cleanup; if (label !=3D NULL && !gfc_reference_st_label (label, ST_LABEL_DO_TARGET)) goto concurr_cleanup; new_st.label1 =3D label; new_st.op =3D EXEC_DO_CONCURRENT; new_st.expr1 =3D mask; new_st.ext.forall_iterator =3D head; return MATCH_YES; concurr_cleanup: gfc_syntax_error (ST_DO); gfc_free_expr (mask); gfc_free_forall_iterator (head); I'm a little lost on how to associate these blocks with OpenMP constructs, however.=