* [PATCH] cgraph_node: Remove redundant section clearing
@ 2022-11-03 20:47 Bernhard Reutner-Fischer
2022-11-03 22:47 ` Jeff Law
2022-11-04 11:55 ` Jan Hubicka
0 siblings, 2 replies; 3+ messages in thread
From: Bernhard Reutner-Fischer @ 2022-11-03 20:47 UTC (permalink / raw)
To: gcc-patches
Cc: Bernhard Reutner-Fischer, Bernhard Reutner-Fischer, Martin Liska,
Jan Hubicka, Martin Jambor
Ok for trunk if testing passes?
gcc/ChangeLog:
* cgraph.cc (cgraph_node::make_local): Remove redundant set_section.
* multiple_target.cc (create_dispatcher_calls): Likewise.
Signed-off-by: Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
---
gcc/cgraph.cc | 1 -
gcc/multiple_target.cc | 1 -
2 files changed, 2 deletions(-)
diff --git a/gcc/cgraph.cc b/gcc/cgraph.cc
index 8d6ed38efa2..36afa6f33f6 100644
--- a/gcc/cgraph.cc
+++ b/gcc/cgraph.cc
@@ -2488,15 +2488,14 @@ cgraph_node::make_local (cgraph_node *node, void *)
{
node->make_decl_local ();
node->set_section (NULL);
node->set_comdat_group (NULL);
node->externally_visible = false;
node->forced_by_abi = false;
node->local = true;
- node->set_section (NULL);
node->unique_name = ((node->resolution == LDPR_PREVAILING_DEF_IRONLY
|| node->resolution == LDPR_PREVAILING_DEF_IRONLY_EXP)
&& !flag_incremental_link);
node->resolution = LDPR_PREVAILING_DEF_IRONLY;
gcc_assert (node->get_availability () == AVAIL_LOCAL);
}
return false;
diff --git a/gcc/multiple_target.cc b/gcc/multiple_target.cc
index 3e2d26882c8..67866a7c963 100644
--- a/gcc/multiple_target.cc
+++ b/gcc/multiple_target.cc
@@ -174,15 +174,14 @@ create_dispatcher_calls (struct cgraph_node *node)
/* FIXME: copy of cgraph_node::make_local that should be cleaned up
in next stage1. */
node->make_decl_local ();
node->set_section (NULL);
node->set_comdat_group (NULL);
node->externally_visible = false;
node->forced_by_abi = false;
- node->set_section (NULL);
DECL_ARTIFICIAL (node->decl) = 1;
node->force_output = true;
}
}
/* Create string with attributes separated by comma.
--
2.38.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] cgraph_node: Remove redundant section clearing
2022-11-03 20:47 [PATCH] cgraph_node: Remove redundant section clearing Bernhard Reutner-Fischer
@ 2022-11-03 22:47 ` Jeff Law
2022-11-04 11:55 ` Jan Hubicka
1 sibling, 0 replies; 3+ messages in thread
From: Jeff Law @ 2022-11-03 22:47 UTC (permalink / raw)
To: Bernhard Reutner-Fischer, gcc-patches
Cc: Jan Hubicka, Bernhard Reutner-Fischer
On 11/3/22 14:47, Bernhard Reutner-Fischer via Gcc-patches wrote:
> Ok for trunk if testing passes?
>
> gcc/ChangeLog:
>
> * cgraph.cc (cgraph_node::make_local): Remove redundant set_section.
> * multiple_target.cc (create_dispatcher_calls): Likewise.
OK after testing passes.
jeff
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] cgraph_node: Remove redundant section clearing
2022-11-03 20:47 [PATCH] cgraph_node: Remove redundant section clearing Bernhard Reutner-Fischer
2022-11-03 22:47 ` Jeff Law
@ 2022-11-04 11:55 ` Jan Hubicka
1 sibling, 0 replies; 3+ messages in thread
From: Jan Hubicka @ 2022-11-04 11:55 UTC (permalink / raw)
To: Bernhard Reutner-Fischer; +Cc: gcc-patches, Bernhard Reutner-Fischer
> Ok for trunk if testing passes?
>
> gcc/ChangeLog:
>
> * cgraph.cc (cgraph_node::make_local): Remove redundant set_section.
> * multiple_target.cc (create_dispatcher_calls): Likewise.
OK (not sure how this slipped in)
The code in create_dispatcher_calls is clearly cut&past of make_local. I
wonder if we should clean up the FIXME :)
thanks!
Honza
>
> Signed-off-by: Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
> ---
> gcc/cgraph.cc | 1 -
> gcc/multiple_target.cc | 1 -
> 2 files changed, 2 deletions(-)
>
> diff --git a/gcc/cgraph.cc b/gcc/cgraph.cc
> index 8d6ed38efa2..36afa6f33f6 100644
> --- a/gcc/cgraph.cc
> +++ b/gcc/cgraph.cc
> @@ -2488,15 +2488,14 @@ cgraph_node::make_local (cgraph_node *node, void *)
> {
> node->make_decl_local ();
> node->set_section (NULL);
> node->set_comdat_group (NULL);
> node->externally_visible = false;
> node->forced_by_abi = false;
> node->local = true;
> - node->set_section (NULL);
> node->unique_name = ((node->resolution == LDPR_PREVAILING_DEF_IRONLY
> || node->resolution == LDPR_PREVAILING_DEF_IRONLY_EXP)
> && !flag_incremental_link);
> node->resolution = LDPR_PREVAILING_DEF_IRONLY;
> gcc_assert (node->get_availability () == AVAIL_LOCAL);
> }
> return false;
> diff --git a/gcc/multiple_target.cc b/gcc/multiple_target.cc
> index 3e2d26882c8..67866a7c963 100644
> --- a/gcc/multiple_target.cc
> +++ b/gcc/multiple_target.cc
> @@ -174,15 +174,14 @@ create_dispatcher_calls (struct cgraph_node *node)
> /* FIXME: copy of cgraph_node::make_local that should be cleaned up
> in next stage1. */
> node->make_decl_local ();
> node->set_section (NULL);
> node->set_comdat_group (NULL);
> node->externally_visible = false;
> node->forced_by_abi = false;
> - node->set_section (NULL);
>
> DECL_ARTIFICIAL (node->decl) = 1;
> node->force_output = true;
> }
> }
>
> /* Create string with attributes separated by comma.
> --
> 2.38.1
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-11-04 11:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-03 20:47 [PATCH] cgraph_node: Remove redundant section clearing Bernhard Reutner-Fischer
2022-11-03 22:47 ` Jeff Law
2022-11-04 11:55 ` Jan Hubicka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).