public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] IPA modref: fix miscompilation in clone when IPA modref is used
@ 2020-10-09 10:26 Martin Liška
  0 siblings, 0 replies; only message in thread
From: Martin Liška @ 2020-10-09 10:26 UTC (permalink / raw)
  To: gcc-patches; +Cc: Jan Hubicka

Hello.

There's a tested Honza's patch for the 2 PRs related to SPEC benchmarks.

Patch can bootstrap on x86_64-linux-gnu and survives regression tests with
one exception:

FAIL: gcc.dg/lto/modref-1 c_lto_modref-1_0.o-c_lto_modref-1_1.o execute -O2 -flto-partition=max -flto

It's a run-time test that tests:
   if (!__builtin_constant_p (z))
     __builtin_abort ();

I guess Honza can incrementally fix the test? I'm going to install the patch.

Thanks,
Martin

gcc/ChangeLog:

	PR ipa/97292
	PR ipa/97335
	* ipa-modref-tree.h (copy_from): Drop summary in a
	clone.
---
  gcc/ipa-modref-tree.h | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gcc/ipa-modref-tree.h b/gcc/ipa-modref-tree.h
index b37280d18c7..8d7f2864793 100644
--- a/gcc/ipa-modref-tree.h
+++ b/gcc/ipa-modref-tree.h
@@ -496,7 +496,8 @@ struct GTY((user)) modref_tree
    /* Copy OTHER to THIS.  */
    void copy_from (modref_tree <T> *other)
    {
-    merge (other, NULL);
+    auto_vec <modref_parm_map, 32> parm_map;
+    merge (other, &parm_map);
    }
  
    /* Search BASE in tree; return NULL if failed.  */
-- 
2.28.0


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

only message in thread, other threads:[~2020-10-09 10:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-09 10:26 [PATCH] IPA modref: fix miscompilation in clone when IPA modref is used Martin Liška

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