public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] ipa: Do not require RECORD_TYPE for ancestor jump functions
@ 2021-11-05 13:25 Martin Jambor
  0 siblings, 0 replies; only message in thread
From: Martin Jambor @ 2021-11-05 13:25 UTC (permalink / raw)
  To: GCC Patches

Hi,

the check this patch removes has remained from times when ancestor
jump functions have been only used for devirtualization and also
contained BINFOs.  It is not necessary now and should have been
removed long time ago.

Pre-approved by Honza and bootstrapped and tested on x86_64-linux, I am
going to push it in a moment.

Martin


gcc/ChangeLog:

2021-11-04  Martin Jambor  <mjambor@suse.cz>

	* ipa-prop.c (compute_complex_assign_jump_func): Remove
	unnecessary check for RECORD_TYPE.
---
 gcc/ipa-prop.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/gcc/ipa-prop.c b/gcc/ipa-prop.c
index 443f21ce61b..e85df0971fc 100644
--- a/gcc/ipa-prop.c
+++ b/gcc/ipa-prop.c
@@ -1421,8 +1421,6 @@ compute_complex_assign_jump_func (struct ipa_func_body_info *fbi,
   if (TREE_CODE (op1) != ADDR_EXPR)
     return;
   op1 = TREE_OPERAND (op1, 0);
-  if (TREE_CODE (TREE_TYPE (op1)) != RECORD_TYPE)
-    return;
   base = get_ref_base_and_extent_hwi (op1, &offset, &size, &reverse);
   offset_int mem_offset;
   if (!base
-- 
2.33.0


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-11-05 13:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-05 13:25 [PATCH] ipa: Do not require RECORD_TYPE for ancestor jump functions Martin Jambor

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).