[llvm-dev] [RFC] Turn the MachineOutliner on by default in AArch64 under -Oz

Jessica Paquette via llvm-dev llvm-dev at lists.llvm.org
Thu Apr 26 11:48:23 PDT 2018


> I don't think this is really the right approach.  With LTO, you can have a mix of functions, some of which are minsize, and some of which are not.  Or with profile info, we might want to outline only cold code (I guess this isn't implemented yet, but potentially future work).  Tying whether we run the outliner to a command-line flag restricts the possible uses; either the entire module gets outlining, or none of it does.


I’ve updated the main patch (https://reviews.llvm.org/D45916 <https://reviews.llvm.org/D45916>) to use this method instead. It’s a lot cleaner and keeps the changes far more self-contained. This should make it easier to define custom outlining behaviour based off function attributes, target-specific requirements, etc. The other patches have been abandoned because they are no longer required.

The compile-time overhead should only appear in AArch64 after this patch. It should only incur the 1% overhead if -Oz is passed in. Otherwise, there will be a very small overhead stemming from looping over the functions in the module and checking for the minsize attribute.

I also fixed the -O3 SPEC failure, so I don’t think that there’s anything outstanding left to fix.

- Jessica

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180426/b41a6bd5/attachment.html>


More information about the llvm-dev mailing list