]> git.ipfire.org Git - thirdparty/gcc.git/commit
Stabilize inliner
authorJan Hubicka <jh@suse.cz>
Fri, 21 Apr 2023 13:46:38 +0000 (15:46 +0200)
committerJan Hubicka <jh@suse.cz>
Fri, 21 Apr 2023 13:46:38 +0000 (15:46 +0200)
commit68c0df8da73cf46e29834cc825f488f4d6b33f98
tree9d685a791deb6e14b3fa9298f4734786ffdfc7b2
parentb5c3abcd77cbca6b2d921fa2f7d21a52e5a36080
Stabilize inliner

The Fibonacci heap can change its behaviour quite significantly for no good
reasons when multiple edges with same key occurs.  This is quite common
for small functions.

This patch stabilizes the order by adding edge uids into the info.
Again I think this is good idea regardless of the incremental WPA project
since we do not want random changes in inline decisions.

gcc/ChangeLog:

2023-04-21  Jan Hubicka  <hubicka@ucw.cz>
    Michal Jires  <michal@jires.eu>

* ipa-inline.cc (class inline_badness): New class.
(edge_heap_t, edge_heap_node_t): Use inline_badness for badness instead
of sreal.
(update_edge_key): Update.
(lookup_recursive_calls): Likewise.
(recursive_inlining): Likewise.
(add_new_edges_to_heap): Likewise.
(inline_small_functions): Likewise.
gcc/ipa-inline.cc