From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-x12c.google.com (mail-lf1-x12c.google.com [IPv6:2a00:1450:4864:20::12c]) by sourceware.org (Postfix) with ESMTPS id 1ECCA385781F; Thu, 18 Mar 2021 13:22:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 1ECCA385781F Received: by mail-lf1-x12c.google.com with SMTP id a198so4557833lfd.7; Thu, 18 Mar 2021 06:22:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=A8h2PhulkorU+IsAisl5WnC+D4HxyUDiELrM6vaA4kE=; b=HGd62xY1LvgJEzs0GNu7hUtWkBMlKUaLE3d0fEjvOtNtbm48tv6rT1RASF/1yguWaA Gi3Xybzk+sB4SrqPyoJ11GMNxLmEFDItlJzLXMK0egQaE1zkQ98ubQNDAuhwFNjKMFmK kMLMkwCGlheRSttIf2qJmBLRP64FRv6BFyuYT44LYsQV5UXVcsqD2YYoigClH57Kn7aQ qr8hOXCovdvi+eiNZZ+jy9ebV33W1sXFuxcab6Q2X+l2egQ0S5vmWd4RIavFZkS3DZQI vL8wq+mAo9ju54Xs751csZPkvs23+c7EF/uDRV5EvJLA31fjwBwVrE9DiGaRBn2nmHa6 OGQw== X-Gm-Message-State: AOAM5322OctRJ5ntFLdoGYDBPgjkI0Fx4R3gM3FxD2oh6vIBCxa+VJvM Ls1/yaEfMh/qtgk1U8rRKZu+J8j/huq6gTYBJcI= X-Google-Smtp-Source: ABdhPJzAmCDIqcH70C7OB4vT5Tt1+j6fY7lzxYLT9HsMqSB3H07w2xrJ8wJsjmllYdefIulP2l0aIjTvSOuwBcciRwU= X-Received: by 2002:a05:6512:1155:: with SMTP id m21mr609292lfg.44.1616073773842; Thu, 18 Mar 2021 06:22:53 -0700 (PDT) MIME-Version: 1.0 References: <4ee532b7-eed8-8dd7-4e01-9a2e8004007c@codesourcery.com> <2c797dfe-a401-0f2a-b121-e6ba0c98179b@codesourcery.com> In-Reply-To: <2c797dfe-a401-0f2a-b121-e6ba0c98179b@codesourcery.com> From: Paul Richard Thomas Date: Thu, 18 Mar 2021 13:22:41 +0000 Message-ID: Subject: Re: [Patch, fortran] PR99602 - [11 regression] runtime error: pointer actual argument not associated To: Tobias Burnus Cc: "fortran@gcc.gnu.org" , gcc-patches , =?UTF-8?Q?J=C3=BCrgen_Reuter?= , Harald Anlauf X-Spam-Status: No, score=-3.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, HTML_MESSAGE, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: fortran@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Fortran mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Mar 2021 13:22:57 -0000 Hi Tobias, Thanks for the review. I am resisting dg-run for this patch simply because the testsuite already takes an oppressive amount of time to run. That the runtime error is present in the code should be sufficient IMHO. Regards Paul On Thu, 18 Mar 2021 at 08:46, Tobias Burnus wrote= : > Hi Paul, hi all fortran@/gcc-patch@ reader, > > it looks as if you replied with your patch submission to the wrong email > address =E2=80=93 and your re-submission ended up at > https://gcc.gnu.org/PR99602#c17 > > On 16.03.21 18:08, Tobias Burnus wrote: > > On 16.03.21 17:42, Paul Richard Thomas via Gcc-patches wrote: > >> Fortran: Fix runtime errors for class actual arguments [PR99602]. > >> * trans-array.c (gfc_conv_procedure_call): For class formal > >> arguments, use the _data field attributes for runtime errors. > >> * gfortran.dg/pr99602.f90: New test. > > Shouldn't there be also a testcase which triggers this run-time error? > > Note: The new submission consists of a new testcase (now two) and the > actual patch; the new testcase removes 'pointer' from the dummy argument > of prepare_m2_proc/prepare_whizard_m2 and checks via the > -ftree-original-dump that there is now run-time check code inserted when > passing a (nullified) pointer to a nonpointer dummy argument. > > Compared to previous patch, 'fsym_attr.pointer =3D > fsym_attr.class_pointer' is new, before it was 'fsym_attr.pointer =3D > fsym_attr.pointer'. > > Paul Richard Thomas wrote in PR99602: > > > Good morning all, > > > > I have attached the revised patch and an additional testcase. I had > totally > > forgotten about the class pointer gotcha. > > > > OK for master? > > > > Paul > > > > Fortran: Fix runtime errors for class actual arguments [PR99602 < > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99602>]. > > LGTM =E2=80=93 thanks for the patch. > > I am wondering whether the second testcase should be a 'dg-do run' test > instead of 'compile' to ensure that the error is indeed triggered > (currently, it only checks the tree dump that a check is inserted). What > do you think? [If you do so, you need a dg-shouldfail + dg-output, cf. > e.g. pointer_check_5.f90.] > > Thanks, > > Tobias > > ----------------- > Mentor Graphics (Deutschland) GmbH, Arnulfstrasse 201, 80634 M=C3=BCnchen > Registergericht M=C3=BCnchen HRB 106955, Gesch=C3=A4ftsf=C3=BChrer: Thoma= s Heurung, Frank > Th=C3=BCrauf > --=20 "If you can't explain it simply, you don't understand it well enough" - Albert Einstein