From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa1.mentor.iphmx.com (esa1.mentor.iphmx.com [68.232.129.153]) by sourceware.org (Postfix) with ESMTPS id E3B6A3858289; Wed, 8 Mar 2023 13:29:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E3B6A3858289 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com X-IronPort-AV: E=Sophos;i="5.98,244,1673942400"; d="scan'208";a="103566840" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa1.mentor.iphmx.com with ESMTP; 08 Mar 2023 05:29:00 -0800 IronPort-SDR: fR1s2jWTV0uSug5T9OAG6tRDruQiJR8HKeFKYFZ+zyiCqf5ze46Fk3mk7YNWgtPYPi/6Ob94nJ 6qprR/BPki+uqXeR7nF8PuZ6zeCD7j8XufdP8vH02lccOoPHk6ulgTMK0ylorGshPlq5LlPZFt eJBVQEyhLScTvnF99XomTfLV7uhej5Gr4v4BTp3u/NtRR/AfNoBJ32RsqN5tFq8YHRf4KDWDUH 0e/BiuGI0Bx0xDTJO2ydJX4SQeK07aR8sqKGAfuvvy/HbAJQKME+n2AkzhqIOgQMH+8Zdg6JhZ SKQ= Message-ID: <216e7ff9-4b18-503c-c01f-702ffaba1f9c@codesourcery.com> Date: Wed, 8 Mar 2023 14:28:53 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 Subject: Re: Request for participation in GSoC Content-Language: en-US To: Priyabrata Mondal CC: GCC Mailing List , References: From: Tobias Burnus In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: quoted-printable X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-13.mgc.mentorg.com (139.181.222.13) To svr-ies-mbx-12.mgc.mentorg.com (139.181.222.12) X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00,HEADER_FROM_DIFFERENT_DOMAINS,KAM_DMARC_STATUS,KAM_SHORT,NICE_REPLY_A,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hello, welcome to the GCC/gfortran community. On 08.03.23 14:02, Martin Jambor wrote: > On Sat, Mar 04 2023, Priyabrata Mondal via Gcc wrote: >> I want to >> participate in Google Summer of Code 2023 by contributing to the *Fortra= n =E2=80=93 >> DO CONCURRENT* project, an implementation of loop that executes >> concurrently. I have started to learn about parallel programming and >> Fortran programming language. >> I have good knowledge of C, C++, Javascript, HTML, and CSS= . >> can you suggest some resources so I can learn the technolog= ies >> that are required for this project? >> I will be highly grateful to you forever if you allow me t= o do >> this project under your guidance. > I assume you have read through > https://gcc.gnu.org/wiki/SummerOfCode#Before_you_apply > have you managed to complete the steps outlined there? I wrote the following the other day regarding 'do concurrent': I think there are two parts to it: First, to add the changes of newer Fortran to gfortran and then to actually use them to generate concurrently running code. (Internally, gfortran currently handles 'do concurrent' to run mostly like a normal loop =E2=80=93 except that it annot= ates the loops are independent. =E2=80=93 Real parallelization would be useful, = however.) If you want to see examples, see do_concurrent_1.f90 to do_concurrent_6.f90 in gfortran's testsuite, i.e. gcc/testsuite/gfortran.dg/ in the GCC sources. That's at https://gcc.gnu.org/git/?p=3Dgcc.git;a=3Dtree;f=3Dgcc/testsuite/gfortran.dg= ;hb=3Drefs/heads/master / But it is best to download GCC yourself via Git as described at https://gcc.gnu.org/git.html I want to note that the DO CONCURRENT syntax also permits a mask argument, like in 'do concurrent (i=3D1:5, j=3D1:5, (i/=3Dj))' where the la= st argument selects a subset. For the Fortran standard, see https://gcc.gnu.org/wiki/GFortranStandards Fortran 2018 (=3D 18-007r1) adds for locality specifiers: LOCAL, LOCAL_INIT, SHARED and DEFAULT(NONE). Fortran 202x alias 2023 adds 'reduce' as in 'do concurrent (i =3D 1, n) reduce(+:a, b, c) reduce(max:d, e, f)' I think the first step is to add parsing support for those new features, i.e. store them, check for issues (diagnostic) and then fail with a 'sorry not yet implemented'. The next step would be to implement LOCAL/LOCAL_INIT for running on the host. And then, finally, would be to translate into code which can then be run concurrently. I was thinking of mapping it internally to OpenMP or OpenACC, to be toggled via a commandline option like -fdo-concurrent=3D. * * * And for getting started with GCC, I wrote: I think the first step would be to download GCC and build it. Something like "git clone" as described above, then "mkdir build" (some directory); "cd build" and then "../configure --prefix=3Dwhere-to-install" followed by "make -j12" and "make install". The "-j12" runs 12 build jobs in parallel. How much to use depends on your system. You probably need to install some development versions of libraries such as ISL, gmp, mpfr and mpc. If you don't have them readily, an option is to run ./contrib/download_prerequisites to download those and build them automatically alongside GCC. I hope it helps to get started Tobias ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstra=C3=9Fe 201= , 80634 M=C3=BCnchen; Gesellschaft mit beschr=C3=A4nkter Haftung; Gesch=C3= =A4ftsf=C3=BChrer: Thomas Heurung, Frank Th=C3=BCrauf; Sitz der Gesellschaf= t: M=C3=BCnchen; Registergericht M=C3=BCnchen, HRB 106955