From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ej1-x636.google.com (mail-ej1-x636.google.com [IPv6:2a00:1450:4864:20::636]) by sourceware.org (Postfix) with ESMTPS id 1CC4F3858C50 for ; Fri, 8 Apr 2022 06:38:01 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 1CC4F3858C50 Received: by mail-ej1-x636.google.com with SMTP id r13so15346213ejd.5 for ; Thu, 07 Apr 2022 23:38:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=eGJxt0JEfAfkuyiFkNFJQfvMrEIhSnTei18HYSgHucw=; b=IoKBTRpUK6jClx5TCsDVciUi4+I96vH5SbedB1K0WGkZuq5zcND5uKtBTlp8dgn8Dh AxkXqlWBJtz4dQaWByd7FM1AnIQxBAmhROzDXBI/X4KDr6gEXWXxcXLy5JDoQ+90fGdp Qfnt0CrWyJMv7G0tmoBSmd1NV//U0It0XsZKaduYyA8p8BIlfeq/2Tukvees5gl8Q4fB QMK6WAmadqsjH3Fa2NwK2hI18BDywwoc13EUs514SVqTbk8t5KtOhEtGC9W3CGIIZcTo IaeFqWZPNAxlq1sIH2sLe+ejLlcURTikv22betorMKE144k7/DY0IkV6CDJwGS9oh2Br iaNg== X-Gm-Message-State: AOAM531yCRBxP5iyVi5PKxnWnFyJUefsmUy25wZoQz4x8gkevmgoe5e8 lT2aCTVKB0mXlx/l2lXTKOIeNwyz6G8k6tlLltY= X-Google-Smtp-Source: ABdhPJzEVjMuQGmt2ESCnEzCB7dLU0PA2EuGspBg/UWpTW4JpDGnJEfRRMvoguCC3HraFoNqVuoNBF7C3dMvTRD7mzE= X-Received: by 2002:a17:907:da0:b0:6df:d4a4:9d0f with SMTP id go32-20020a1709070da000b006dfd4a49d0fmr17672598ejc.407.1649399879752; Thu, 07 Apr 2022 23:37:59 -0700 (PDT) MIME-Version: 1.0 References: <20220330233135.1762317-1-indu.bhagat@oracle.com> <787914a7-b950-cbd2-5c72-bbef4510ef67@oracle.com> In-Reply-To: <787914a7-b950-cbd2-5c72-bbef4510ef67@oracle.com> From: Richard Biener Date: Fri, 8 Apr 2022 08:37:48 +0200 Message-ID: Subject: Re: [PATCH 0/3] Fix PR debug/105089 To: Indu Bhagat Cc: GCC Patches Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Apr 2022 06:38:04 -0000 On Thu, Apr 7, 2022 at 9:42 PM Indu Bhagat via Gcc-patches wrote: > > ping The series is OK > On 3/30/22 4:31 PM, Indu Bhagat wrote: > > Hello, > > > > This patch set fixes PR debug/105089. > > > > [PS: The first patch in the series "ctfc: get rid of the static variable in > > ctf_list_add_ctf_vars" is unrelated to the PR and is combined here only for > > ease of review.] > > > > As noted in the PR debug/105089, gcc is emitting two CTF variable records > > where it sees an extern variable with declaration and definition in the same > > compilation unit. > > > > The CTF format format does not distinguish between the non-defining decl vs. > > the defining decl, so the correct behaviour wrt the compiler generating the > > type for such extern variables is to simply emit the type of the defining > > declaration. > > > > Testing Notes: > > -- bootstrapped and reg tested on x86_64 and aarch64 > > -- built binutils package with -gctf (with CTF-capable linker) on x86_64, no > > CTF errors reported. > > > > Thanks, > > > > Indu Bhagat (3): > > ctfc: get rid of the static variable in ctf_list_add_ctf_vars () > > CTF for extern variable fix [PR105089] > > Refactor and update CTF testcases [PR105089] > > > > gcc/ctfc.cc | 62 ++++++++++++++++++- > > gcc/ctfc.h | 8 ++- > > gcc/ctfout.cc | 28 ++++++--- > > gcc/dwarf2ctf.cc | 18 +++++- > > gcc/testsuite/gcc.dg/debug/ctf/ctf-array-2.c | 22 +++---- > > gcc/testsuite/gcc.dg/debug/ctf/ctf-array-5.c | 17 +++++ > > .../gcc.dg/debug/ctf/ctf-variables-3.c | 22 +++++++ > > 7 files changed, 147 insertions(+), 30 deletions(-) > > create mode 100644 gcc/testsuite/gcc.dg/debug/ctf/ctf-array-5.c > > create mode 100644 gcc/testsuite/gcc.dg/debug/ctf/ctf-variables-3.c > > >