From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by sourceware.org (Postfix) with ESMTPS id 1C45C385840E; Mon, 22 Nov 2021 20:30:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 1C45C385840E Received: by mail-wm1-x32a.google.com with SMTP id g191-20020a1c9dc8000000b0032fbf912885so804872wme.4; Mon, 22 Nov 2021 12:30:36 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=NDLz15uDVzRBjFjkRLX8+diOBbJNbpFGZVuQ002DY0E=; b=ECNh9k1shAX8TFP+evJMOqtsj+6UXvTZd3Pz3WAqJQGsA5xbgu/z/KYbJuTfAQx6r6 cuHZ4kBTwz3HCPZRwsWdYTr0jTAqAsajnbW11Ep5ABeWO3QkATlP+qgQ+Wqyg4RMVFFs ++PTXvJUUONMyqEAYR8HUXVO5+kozhJAgb75S05C0211yjLei0yTj8VgxqwJ2+EbjWbk vxJSTzQzL4oOnfuHmNpCbjDpEIPPJABl2C7G/EYQ+etaFnsES/fHmKYfNpY8j1B2wwLr eebGu/zpGVfTk73cQBclFb0adA/It1eTcoANvIkuhOhWeBKBNjxxBxrcMxpEZjMIGHG8 PiMg== X-Gm-Message-State: AOAM533Ar+Nuv/p7eW0JfUx8JQEkPdhEL/YlFsPym8wELQir735dresE vmx7NYXWp+m+9Mdo2ZVrf3w= X-Google-Smtp-Source: ABdhPJysrOMrMT/HcxAKNvKv/4MlpxgWgZQAtmPnHTc/Y4WJyHgeE0szPWV6cWcp4VF7d7GFFKettg== X-Received: by 2002:a05:600c:213:: with SMTP id 19mr31958227wmi.16.1637613035146; Mon, 22 Nov 2021 12:30:35 -0800 (PST) Received: from nbbrfq (dynamic-2bq7di4u2lfl4qjka9-pd01.res.v6.highway.a1.net. [2001:871:227:33a8:f6a3:c58c:7641:e771]) by smtp.gmail.com with ESMTPSA id o25sm11025712wms.17.2021.11.22.12.30.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Nov 2021 12:30:34 -0800 (PST) Date: Mon, 22 Nov 2021 21:30:31 +0100 From: Bernhard Reutner-Fischer To: Mikael Morin Cc: rep.dot.nop@gmail.com, Harald Anlauf via Gcc-patches , Harald Anlauf , fortran , Thomas Koenig Subject: Re: [PATCH] PR fortran/87851 - [9/10/11/12 Regression] Wrong return type for len_trim Message-ID: <20211122213031.31b6c3ba@nbbrfq> In-Reply-To: References: <02b4c4b8-8e3b-ff2e-e5ac-537c1c857380@orange.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org 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: Mon, 22 Nov 2021 20:30:37 -0000 On Mon, 22 Nov 2021 19:17:51 +0100 Harald Anlauf via Gcc-patches wrote: > Am 21.11.21 um 12:46 schrieb Mikael Morin: > > Le 19/11/2021 =C3=A0 20:47, Harald Anlauf via Fortran a =C3=A9crit=C2= =A0: =20 > >> Dear Fortranners, > >> > >> scalariziation of the elemental intrinsic LEN_TRIM was ICEing > >> when the optional KIND argument was present. > >> > >> The cleanest solution is to use the infrastructure added by > >> Mikael's fix for PR97896.=C2=A0 In that case it is a 1-liner.=C2=A0 :-) I'm just wondering loud if it would be more convenient to have a unsigned hidden_arg:1 bit in let's say gfc_actual_arglist that denotes if the argument should be const eval'ed and used before, and, most importantly not passed to the library. We seem to have more than just the index intrinsic's kind arg in that boat. And from what i read, powerpc will eventuall want to select quite some kind-specific library functions soon, depending on how this part is implemented.. Maybe add SPEC_HIDDEN_ARG / SPEC_LIBRARY_SELECTOR additional gfc_param_spec_type if a separate bit is deemed inappropriate. Such a hidden_arg/library_selector/non_library_call_arg flag is maybe better than matching individual functions and strcmp the arg name. cheers,