From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) by sourceware.org (Postfix) with ESMTPS id C4A233858CDB; Wed, 29 Mar 2023 08:24:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C4A233858CDB Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmx.ch Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmx.ch DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.ch; s=s31663417; t=1680078289; i=manfred99@gmx.ch; bh=lWLHekQHUISXSPETGmC4icHYaAl+8dCx7apA6iRGwT4=; h=X-UI-Sender-Class:Date:Subject:To:References:From:Cc:In-Reply-To; b=CJ4TN1yjKKqmwDV3tDcrO+vvYdlM4Jocz/bhg0GdsnHys7dJU4fu/kfxsmgAznmzd M988e+MEqFm9I636Qigt3nfCrgMhHDYnRe7CbZmoUXbOYeJFMR4ESpk+O78aEcoxfT hjcjWO/Rc0wV5TuGbBdZ9APogIQqlUnvx8aA5PfLtzPFIhMylTzhbKNDj0th/VZyHM voT9rDFLisoRIsMJsJX2egxF20xECreOa3fnXppkD09mfQ6VbkySMMp1IgRnKSyJoz yCVGF9j2ghVVXzlo3tJ93WncNUlb0wTOJRE8JneyogLbWqN7FgCFYFaNh/DYO6JU9M A2s6XA1h5HSYw== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from [192.168.99.12] ([212.126.164.126]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N5G9n-1qQ0n73lPp-0119Uy; Wed, 29 Mar 2023 10:24:48 +0200 Message-ID: <0a9997a2-819e-40bc-4623-a4dbd3507a32@gmx.ch> Date: Wed, 29 Mar 2023 10:24:48 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 Subject: Re: [Patch, fortran] PR87477 - [meta-bug] [F03] issues concerning the ASSOCIATE statement To: Paul Richard Thomas References: Content-Language: de-CH From: Manfred Schwarb Cc: gcc-patches , "fortran@gcc.gnu.org" In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:d2OIyqrQwDzgy8/pmfAziVgnQ3Jnyzwsno/pqeqKVTSufdgAVnT uYWPTddWuQUDD/MolqhoAojXapXTGiIdkK7Fnw93WJceem7Sk3Ms01sbbJHeugyxQxLpAsi 2WnNSCn4azHrptcofU8c91hRZNAWnUk9rn86KVEAhFwo7lLTJRMkCywkbHYWXVzhVJIY04s 4O0BTE1FaEmSXSXxYoSmA== UI-OutboundReport: notjunk:1;M01:P0:OZeH+HEjC8Y=;lzwKtc90VhtqyRX00lFmBrNGU9g EXqnsS0qG5F3VghkMgas2i09rlW8HFCvtMxjYa9PYrMNW1OUBLQO0M+W3hpevHfDKzs2aq3X3 OFgT4Zk39yqNh0IQSkPTte+fkFgA7Pwotg2gf3nbLWCa7vxkGNZCbv4ZHZ2AvDtW0OB24K3bs hH/s1a4TeuxrrqtHgqy13Xi+QIidFvkGcBVJ7url+2S0H2OAbgV3pY5jFSxj6+BIULqYSKWvM z2FiAwjtbwl70ajsrtCsdBZWDDIWVXG2rBVNMVmZD1YP+RXOsUCIN79bpR6wQRcXsVbmFIZs3 TTaoBjm31n0aJZZT2tFU04Ggsa3hqPyx/VeAlDwuBoJwLwll2hgM3NnpNGoZ7xU6sE3Ym3rPO g8ITEDn4e82NV0yHKLJpAcx+tES9Hi2jGxlqCcVFhGo46Y6eSZgha2/ma/BPKMCHNNAhbAXMa ukCOStLKDikG9rH1GkxPAvXzuTBH7859UfyIWyIEQJcKkFBXsgkzT2ENwx8DflZmzJI+w2FUw xncRZSLdOg4h4dby16peVAanWA/PgVRdykLGA6YwFxMME5e0HH3edQXuJ37XePNZFKIj4JjJH IbbvQ0aRiU58EmgnHClsiNcT9URfSARG2asrk0qdFlgM8SI7PtLKMZIVVXx5Ys2OeBQpV1Fdr FCuLBPbhEp4SKeeJbM6abmNR6ikkfxLgU3onMBO2m2yW56In8qXn3US9i9s57492IixBKwlcU 7B46abgwlelHRRwgTogNqFNUuZ0LDpdr36hBZU4QhGuTEj3AyrVl3D/Wx7Nb2ebK/0TgHKRu9 jwT/mguOR46fgdqFZ4cvItr1owaSZ8SYQpJLCI7g4H8Cjx5rP77WTk+w6GI9Ol6ZqrvbyeymS GAfW4dHcUofvOmxD4Hm4KWkyEleCW+sXd8MSRBKI7BfeeZFVGdQRZ2EyQOn8v34VjGc9fiL9J 0/1XH6ae1VPrWh6ncZlCTLhQXt8= X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,NICE_REPLY_A,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Am 28.03.23 um 23:04 schrieb Paul Richard Thomas via Fortran: > Hi All, > > I have made a start on ASSOCIATE issues. Some of the low(-ish) hanging > fruit are already fixed but I have yet to check that they a really fixed > and to close them: > pr102106, pr102111, pr104430, pr106048, pr85510, pr87460, pr92960 & pr93= 338 > > The attached patch picks up those PRs involving deferred length characte= rs > in one guise or another. I believe that it is all pretty straightforward= . > Structure constructors with allocatable, deferred length, character arra= y > components just weren't implemented and so this is the biggest part of t= he > patch. I found two other, non-associate PRs(106918 & 105205) that are > fixed and there are probably more. > > The chunk in trans-io.cc is something of a kludge, which I will come bac= k > to. Some descriptors come through with a data pointer that looks as if i= t > should be OK but > > I thought to submit this now to get it out of the way. The ratio of PRs > fixed to the size of the patch warrants this. The next stage is going to= be > rather messy and so "I might take a little while" (cross talk between > associate and select type, in particular). > > Regtests OK - good for mainline? > Paul, you have some "dg-do-run" and "dg-do-compile" statements in your tes= tcases, could you change them into their single-minus-sign variants? Cheers, Manfred BTW: I just ran my script again and found the following testsuite issues (= note that outer-most braces need to be space-padded): ./c-interop/removed-restrictions-1.f90:! { dg-do compile} ./c-interop/removed-restrictions-2.f90:! { dg-do compile} ./c-interop/removed-restrictions-3.f90:! { dg-do compile} ./c-interop/removed-restrictions-4.f90:! { dg-do compile} ./c-interop/tkr.f90:! { dg-do compile} ./c-interop/c407c-1.f90:! { dg-do compile} ./c-interop/deferred-character-1.f90:! { dg-do compile} ./c-interop/allocatable-optional-pointer.f90:! { dg-do compile} ./c-interop/c407a-1.f90:! { dg-do compile} ./c-interop/c407b-1.f90:! { dg-do compile} ./c-interop/c407b-2.f90:! { dg-do compile} ./c-interop/c535a-1.f90:! { dg-do compile} ./c-interop/c535a-2.f90:! { dg-do compile} ./c-interop/c535b-1.f90:! { dg-do compile} ./c-interop/c535b-2.f90:! { dg-do compile} ./c-interop/c535b-3.f90:! { dg-do compile} ./c-interop/c535c-1.f90:! { dg-do compile} ./c-interop/c535c-2.f90:! { dg-do compile} ./gomp/affinity-clause-1.f90:! { dg final { scan-tree-dump-times "#pragma = omp task affinity\\(iterator\\(integer\\(kind=3D4\\) i=3DD\\.\[0-9\]+:5:1\= \):b\\\[\\(.* ? \\+ -1\\\]\\) affinity\\(iterator\\(integer\\(kind=3D4= \\) i=3DD\\.\[0-9\]+:5:1\\):d\\\[\\(\\(integer\\(kind=3D8\\)\\) i \\+ -1\\= ) \\* 6\\\]\\)" 1 "original" } } ./class_result_10.f90:! { dg-do run} ./pr103258.f90:! { dg-do compile} ./dtio_35.f90:! { dg-compile } ./pr93835.f08:! {dg-do run } ./pr59107.f90:! { dg-compile } > Cheers > > Paul > > Fortran: Fix some of the bugs in associate [PR87477] > > 2023-03-28 Paul Thomas > > gcc/fortran > PR fortran/87477 > * trans-array.cc (gfc_conv_expr_descriptor): Guard string len > expression in condition. > (duplicate_allocatable): Make element type more explicit with > 'eltype'. > * trans-expr.cc (gfc_get_expr_charlen): Retain last charlen in > 'previous' and use if end expression in substring reference is > null. > (gfc_conv_string_length): Use gfc_conv_expr_descriptor if > 'expr_flat' is an array. > (gfc_trans_alloc_subarray_assign): If this is a deferred string > length component, store the string length in the hidden comp. > Update the typespec length accordingly. Generate a new type > spec for the call to gfc_duplicate-allocatable in this case. > * trans-io.cc (gfc_trans_transfer): Scalarize transfer of > deferred character array components. > > > gcc/testsuite/ > PR fortran/92994 > * gfortran.dg/finalize_51.f90 : Update an error message. > > PR fortran/85686 > * gfortran.dg/pr85686.f90 : New test > > PR fortran/88247 > * gfortran.dg/pr88247.f90 : New test > > PR fortran/91941 > * gfortran.dg/pr91941.f90 : New test > > PR fortran/92779 > * gfortran.dg/pr92779.f90 : New test > > PR fortran/93339 > * gfortran.dg/pr93339.f90 : New test > > PR fortran/93813 > * gfortran.dg/pr93813.f90 : New test > > PR fortran/100948 > * gfortran.dg/pr100948.f90 : New test > > PR fortran/102106 > * gfortran.dg/pr102106.f90 : New test > > PR fortran/105205 > * gfortran.dg/pr105205.f90 : New test > > PR fortran/106918 > * gfortran.dg/pr106918.f90 : New test