https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63796
Jan Hubicka <hubicka at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hubicka at gcc dot gnu.org --- Comment #2 from Jan Hubicka <hubicka at gcc dot gnu.org> --- I looked into this testcase, not sure why I did not commit the change. The problem is that we do not eliminate the dead function body (because we devirtualize late) and therefore we end up with 3 "return 2" statements. I guess it is not kind of optimization we can easily implement in 5.0 so I will update the template count.