https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83411
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2017-12-14 CC| |marxin at gcc dot gnu.org Component|tree-optimization |ipa Ever confirmed|0 |1 Severity|normal |enhancement --- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- It's generally difficult to do this given there exist things like a) calls to external functions (would be eventually visible and thus versionable when using LTO) b) indirect function calls So getting consistent behavior (and well-documented behavior) for the user would be difficult. We do have a similar feature which is the 'flatten' attribute which inlines a sub-callgraph as far as possible. Not sure if we solved the consistent behavior and documentation thing there ;) Anyway, I can see how this is useful. It looks there's also a related "bug" in that we go through repeated dispatching when calling functions from identical MV context? IIRC a duplicate bug about that, if you can't find it mind opening a missed-optimization one for this?