https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69589
--- Comment #13 from Martin Jambor <jamborm at gcc dot gnu.org> --- (In reply to kugan from comment #11) > In remove_unreachable_nodes, just before ipa-cp, this node becomes local > (address taken is false and local.local = true). After that, when > ipa_propagate_frequency is run, which updates the frequency to zero. I think > we should check the frequency at this point in time and remove such nodes. If remove_unreachable_nodes keeps the node around for comdat reasons, we cannot remove it just because it has zero estimated frequency (unless remove_unreachable_nodes was wrong and should have removed the node itself). I think that remove_unreachable_nodes should either remove the node, or not set it to local (or set something like force_output or forced_by_abi, if it is some really weird case).