Message ID | da61795c-6b32-4e0e-9e03-bb90b900e961@suse.cz |
---|---|
State | New |
Headers |
Return-Path: <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 61A0F3858429 for <patchwork@sourceware.org>; Mon, 8 Nov 2021 10:53:39 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by sourceware.org (Postfix) with ESMTPS id BC4173858415 for <gcc-patches@gcc.gnu.org>; Mon, 8 Nov 2021 10:53:22 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org BC4173858415 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id AE08A2193C; Mon, 8 Nov 2021 10:53:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1636368801; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bfDssM6aJ2knIAFadb+QrOT8KMx5jKO6q5gMQBUSqA4=; b=wpf5mRbevr7zEjdYqzbpVCUtSNuPM7OjAmZoTsLoLBVuN8LUkdUT9YG4UMhaG4pP8aAepW fitBnER7aQAfNT/x2FhVNbs9A+v8mq54Pp3tFH676HBk7i0YMfgNnxxG9p+n9hVILees9J G4xgl0O/RBBPD/POnTvYK25recLtLxs= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1636368801; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bfDssM6aJ2knIAFadb+QrOT8KMx5jKO6q5gMQBUSqA4=; b=ubYZT9l79Vxq7suZ9amssc8oQJNc66dGE0IbFwQJavIpDMMtLCeiLMDkjYEbIMyncFIAWd kOi/bAPfZmEswzBg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 9133913B04; Mon, 8 Nov 2021 10:53:21 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id t9WxIaEBiWF5LAAAMHmgww (envelope-from <mliska@suse.cz>); Mon, 08 Nov 2021 10:53:21 +0000 Message-ID: <da61795c-6b32-4e0e-9e03-bb90b900e961@suse.cz> Date: Mon, 8 Nov 2021 11:53:21 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.0 From: =?utf-8?q?Martin_Li=C5=A1ka?= <mliska@suse.cz> Subject: [PATCH] Dump static chain for cgraph_node. To: gcc-patches@gcc.gnu.org Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-11.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, 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: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Cc: Jan Hubicka <hubicka@ucw.cz> Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> |
Series |
Dump static chain for cgraph_node.
|
|
Commit Message
Martin Liška
Nov. 8, 2021, 10:53 a.m. UTC
Patch can bootstrap on x86_64-linux-gnu and survives regression tests. Ready to be installed? Thanks, Martin gcc/ChangeLog: * cgraph.c (cgraph_node::dump): Dump static_chain_decl. --- gcc/cgraph.c | 4 ++++ 1 file changed, 4 insertions(+)
Comments
> Patch can bootstrap on x86_64-linux-gnu and survives regression tests. > > Ready to be installed? > Thanks, > Martin > > gcc/ChangeLog: > > * cgraph.c (cgraph_node::dump): Dump static_chain_decl. OK Honza > --- > gcc/cgraph.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/gcc/cgraph.c b/gcc/cgraph.c > index de078653781..8299ee92946 100644 > --- a/gcc/cgraph.c > +++ b/gcc/cgraph.c > @@ -2203,6 +2203,10 @@ cgraph_node::dump (FILE *f) > fprintf (f, " %soperator_delete", > DECL_IS_REPLACEABLE_OPERATOR (decl) ? "replaceable_" : ""); > + function *fn = DECL_STRUCT_FUNCTION (decl); > + if (fn != NULL && fn->static_chain_decl) > + fprintf (f, " static_chain_decl"); > + > fprintf (f, "\n"); > if (thunk) > -- > 2.33.1 >
> diff --git a/gcc/cgraph.c b/gcc/cgraph.c > index de078653781..8299ee92946 100644 > --- a/gcc/cgraph.c > +++ b/gcc/cgraph.c > @@ -2203,6 +2203,10 @@ cgraph_node::dump (FILE *f) > fprintf (f, " %soperator_delete", > DECL_IS_REPLACEABLE_OPERATOR (decl) ? "replaceable_" : ""); > > + function *fn = DECL_STRUCT_FUNCTION (decl); > + if (fn != NULL && fn->static_chain_decl) > + fprintf (f, " static_chain_decl"); > + > fprintf (f, "\n"); > > if (thunk) static_chain_decl is not a flag though, it's a tree.
> > diff --git a/gcc/cgraph.c b/gcc/cgraph.c > > index de078653781..8299ee92946 100644 > > --- a/gcc/cgraph.c > > +++ b/gcc/cgraph.c > > @@ -2203,6 +2203,10 @@ cgraph_node::dump (FILE *f) > > fprintf (f, " %soperator_delete", > > DECL_IS_REPLACEABLE_OPERATOR (decl) ? "replaceable_" : ""); > > > > + function *fn = DECL_STRUCT_FUNCTION (decl); > > + if (fn != NULL && fn->static_chain_decl) > > + fprintf (f, " static_chain_decl"); > > + > > fprintf (f, "\n"); > > > > if (thunk) > > static_chain_decl is not a flag though, it's a tree. Ah yes, you want to just test if (DECL_STATI_CHAIN (decl)) and then print "static_chain". I was not reading carefuly enough. Thanks! Honza > > -- > Eric Botcazou > >
On 11/8/21 12:17, Jan Hubicka wrote: >>> diff --git a/gcc/cgraph.c b/gcc/cgraph.c >>> index de078653781..8299ee92946 100644 >>> --- a/gcc/cgraph.c >>> +++ b/gcc/cgraph.c >>> @@ -2203,6 +2203,10 @@ cgraph_node::dump (FILE *f) >>> fprintf (f, " %soperator_delete", >>> DECL_IS_REPLACEABLE_OPERATOR (decl) ? "replaceable_" : ""); >>> >>> + function *fn = DECL_STRUCT_FUNCTION (decl); >>> + if (fn != NULL && fn->static_chain_decl) >>> + fprintf (f, " static_chain_decl"); >>> + >>> fprintf (f, "\n"); >>> >>> if (thunk) >> >> static_chain_decl is not a flag though, it's a tree. > Ah yes, you want to just test if (DECL_STATI_CHAIN (decl)) > and then print "static_chain". > I was not reading carefuly enough. Thanks! Oh, ok. One can read it from decl. Pushed with the modification as g:409767d774c59ee4c3eefca5015ba00539fddc08. Cheers, Martin > Honza >> >> -- >> Eric Botcazou >> >>
On 11/8/21 12:51, Martin Liška wrote:
> Pushed with the modification as g:409767d774c59ee4c3eefca5015ba00539fddc08.
Sorry, I forgot to commit it, so fixed in:
https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=355eb60b6672220642fae853021599afaa87dfd6
Martin
diff --git a/gcc/cgraph.c b/gcc/cgraph.c index de078653781..8299ee92946 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -2203,6 +2203,10 @@ cgraph_node::dump (FILE *f) fprintf (f, " %soperator_delete", DECL_IS_REPLACEABLE_OPERATOR (decl) ? "replaceable_" : ""); + function *fn = DECL_STRUCT_FUNCTION (decl); + if (fn != NULL && fn->static_chain_decl) + fprintf (f, " static_chain_decl"); + fprintf (f, "\n"); if (thunk)