From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg1-x52a.google.com (mail-pg1-x52a.google.com [IPv6:2607:f8b0:4864:20::52a]) by sourceware.org (Postfix) with ESMTPS id DA5643858D26; Thu, 23 May 2024 07:03:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DA5643858D26 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org DA5643858D26 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::52a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1716447841; cv=none; b=KhQEOJth0tgz20giVAMXwuK5ZBclPP5jpDquNl2/kc/UNcaWTn1/Wlm96ISqd7ihwvIRjU+00jLL2/cVkYho2KTMgCXnviECFzh72q2jm1/Y4HjgJsCv0MblYeDq8VhoHKqk/pEzqoQiATRDQaBiXh8f/LH14xocSfbY8+fnxSE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1716447841; c=relaxed/simple; bh=W/iMhzMRQGEp1k3i6aArBa/2J0xBQ0jsXbGEL6+DUE0=; h=DKIM-Signature:MIME-Version:From:Date:Message-ID:Subject:To; b=Z8t0vAQyxrvz0k1Wm/D07nKvgZhSOwIEI1TV/uJysGL2vfE2DsSiQG7TvssuBXUpPuuVyiYdCwjLluBw7oId327SeLb2cLUU+UU9+lSf9EtEOevXWgq3AJTQ8hyThDPlGZlgvrKyhAXH+NTiMinK4cwLZeZN4qu5QmRYXr51B5Q= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pg1-x52a.google.com with SMTP id 41be03b00d2f7-67af3f6cbb3so404139a12.0; Thu, 23 May 2024 00:03:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716447835; x=1717052635; darn=gcc.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=MtorC0G2S2+t/wNdSSsqpGshc9BfOz8VuHn8ybLoqYk=; b=Ocrf23FEQN34LLW3WenA2PC83um5zA3EPDIZg+CZCLdOvXUkdSTzR+Fly65h/LK77+ 1XAjB36ZaSojq2lRqkJCHZ8P0va0MrrCKEhbjyi3yB6WY8UDj7zrVyCMCa2Zluy517a9 G3eSW8GJitOV/JWreA7UG0sNjzz/w1+cTp4Zn8s93xBQRNOBBLV5CfoPTKKgnAYrx1wc Q/fqR2sb3AdTPi9OKxwRvpuEiFxDyLyzGKuZ326I/AhwinZR7Yf2PjCRLAXL63jYqwy+ 9cVWdKcZgKj+SyJtK/B7miy13Of8HsONVH2tG6v9QzCrftwlOoDmesih2iffvs9WXm09 ENfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716447835; x=1717052635; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=MtorC0G2S2+t/wNdSSsqpGshc9BfOz8VuHn8ybLoqYk=; b=s6ISO/95rMH3sMqRdaSufOokz0XRw1bRfDuAG36/hqt+fCq2DAkdpSze3t4bllwPap yd03RNkSERECjK0vCqHuflJXWnFn63S5XUTVF7Tg8UNmaXxn+IoqScH+J9OxK2k3GZfp e5IpyDzCrF6r4obRGtPzG7wozUgLrbPKx9GqVF4FvB5LNq3lrgrqtuVmrJ8MJAQEK0CP sQD9DxH7i4sjzIyIbU6pP074ow7rNgvavfan18lD4VKfnQH4fS9I0P6pFXF4uzx20mbp DM7ijs/PbHhL4CD4zbj9lPMTtf6kBsXB35ECnBXiaKgx8GrmbFMbdtCyUvLGc2yUb8Ku /+0A== X-Forwarded-Encrypted: i=1; AJvYcCUuTiGgpLt55GnOcW+YTwSnJcUd9r2NNfn0218GNLWLxkMvYvgRv4FhJOQF/LewhGmzCiH/lOQ7g6eTw4RdhZhvaaTbciWWDA== X-Gm-Message-State: AOJu0YzEQsj0LrZCx2OVDFkkygTu61vZ4aFRGE3qM9xF5WAbcpjY/kOo BZOFVb5rSmyHOPdtLPbb3hsjuZZ9Pxf0LAMUsujAywruCF9FKzMhkDOzdHPIWcQfZPt19liBDUO ramSIonYXR/TSQHMDaopArnxgRNO5lA== X-Google-Smtp-Source: AGHT+IEw9awHRYoFB4S/1BkhxcEpy9pqN3TwyiL4/MHJT07BRnk5DD5MeHYU3sY9TRM+4QKfibLSujptNpmu7axguuE= X-Received: by 2002:a17:90a:c301:b0:2b5:9534:56d6 with SMTP id 98e67ed59e1d1-2bddcf26e97mr1821302a91.24.1716447834638; Thu, 23 May 2024 00:03:54 -0700 (PDT) MIME-Version: 1.0 References: <31e4d136-6271-496c-a0fd-d475cdee1a3a@gmx.de> In-Reply-To: <31e4d136-6271-496c-a0fd-d475cdee1a3a@gmx.de> From: Paul Richard Thomas Date: Thu, 23 May 2024 08:03:43 +0100 Message-ID: Subject: Re: [Patch, fortran] PR103312 - [11/12/13/14/15 Regression] ICE in gfc_find_component since r9-1098-g3cf89a7b992d483e To: Harald Anlauf Cc: "fortran@gcc.gnu.org" , gcc-patches Content-Type: multipart/alternative; boundary="00000000000075986a061919a716" X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,GIT_PATCH_0,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,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: --00000000000075986a061919a716 Content-Type: text/plain; charset="UTF-8" Hi Harald, You were absolutely right about returning 'false' :-) The patch is duly corrected. Committed to mainline and will be followed by backports in a few weeks. Regards Paul On Tue, 21 May 2024 at 19:58, Harald Anlauf wrote: > Hi Paul, > > Am 20.05.24 um 11:06 schrieb Paul Richard Thomas: > > Hi All, > > > > I don't think that this PR is really a regression although the fact that > it > > is marked as such brought it to my attention :-) > > > > The fix turned out to be remarkably simple. It was found after going > down a > > silly number of rabbit holes, though! > > > > The chunk in dependency.cc is probably more elaborate than it needs to > be. > > Returning -2 is sufficient for the testcase to work. Otherwise, the > > comments in the patch say it all. > > this part looks OK, but can you elaborate on this change to expr.cc: > > diff --git a/gcc/fortran/expr.cc b/gcc/fortran/expr.cc > index c883966646c..4ee2ad55915 100644 > --- a/gcc/fortran/expr.cc > +++ b/gcc/fortran/expr.cc > @@ -3210,6 +3210,11 @@ gfc_reduce_init_expr (gfc_expr *expr) > { > bool t; > > + /* It is far too early to resolve a class compcall. Punt to > resolution. */ > + if (expr && expr->expr_type == EXPR_COMPCALL > + && expr->symtree->n.sym->ts.type == BT_CLASS) > + return true; > + > > I would have expected to return 'false' here, as we do not > have an expression that reduces to a constant. What am I > missing? > > (The testcase compiles and works here also when using 'false'.) > > > OK for mainline? I will delay for a month before backporting. > > OK if can you show me wrong... > > Thanks, > Harald > > > Regards > > > > Paul > > > > --00000000000075986a061919a716--