This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug ipa/64694] [5 Regression] FAIL: 23_containers/unordered_set/insert/hash_policy.cc


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64694

--- Comment #7 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Jan Hubicka from comment #6)
> > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64694
> > 
> > --- Comment #5 from Jan Hubicka <hubicka at ucw dot cz> ---
> > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64694
> > > 
> > > --- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> ---
> > > r219076 introduced:
> > > 
> > >       if (current_badness != badness)
> > >         {
> > >           if (edge_heap.min () && badness > edge_heap.min_key ())
> > >                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> > >                                   Does it look right?
> > 
> > This is a thinko, indeed.  I am testing a fix, but I doubdt this can affect
> > correctness

This patch

---
diff --git a/gcc/ipa-inline.c b/gcc/ipa-inline.c
index da1afc6..aa93928 100644
--- a/gcc/ipa-inline.c
+++ b/gcc/ipa-inline.c
@@ -1794,7 +1794,7 @@ inline_small_functions (void)
 #endif
       if (current_badness != badness)
   {
-    if (edge_heap.min () && badness > edge_heap.min_key ())
+    if (edge_heap.min () && current_badness > edge_heap.min_key ())
       {
         edge->aux = edge_heap.insert (current_badness, edge);
         continue;
---

works for me.

> > of a testcase.  I see it does inlining, but why it depends on inline decisions?
> I meant unwinding.
> 

That is a very interesting question.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]