[LLVMdev] Postponing more passes in LTO

Greg Bedwell gregbedwell at gmail.com
Thu Dec 18 13:09:55 PST 2014


This looks really interesting.  As my colleague Gao mentioned in his
lightning talk on our LTO implementation at the last developer meeting
we're definitely interested in seeing if there are any potential gains to
be had by deferring passes.

I'd like to give it a try on some of our codebases, although with the
Christmas break coming up and various other commitments after that in
January I'm not sure when I'll be able to look at it properly.  If there is
any other followup here, then please don't let that block anything from
moving forward, but otherwise I'll do my best to reply here as soon as I
possibly can after doing some experimentation!

Greg Bedwell
SN Systems - Sony Computer Entertainment Group

On 15 December 2014 at 19:27, Daniel Stewart <stewartd at codeaurora.org>
wrote:
>
> I have done some preliminary investigation into postponing some of the
> passes to see what the resulting performance impact would be. This is a
> fairly crude attempt at moving passes around to see if there is any
> potential benefit. I have attached the patch I used to do the tests, in
> case anyone is interested.
>
>
>
> Briefly, the patch allows two different flows, with either a flag of
> –lto-new or –lto-new2. In the first case, the vectorization passes are
> postponed from the end of populateModulePassManager() function to midway
> through the addLTOOptimizationPasses(). In the second case, essentially the
> entire populateModulePassManager() function is deferred until link time.
>
>
>
> I ran spec2000/2006 on an ARM platform (Nexus 4), comparing 4
> configurations (O3, O3 LTO, O3 LTO new, O3 LTO new 2). I have attached a
> PDF presenting the results from the test. The first 4 columns have the spec
> result (ratio) for the 4 different configurations. The second set of
> columns are the respective test / max(result of 4 configurations). I used
> this last one to see how well/poor a particular configuration was in
> comparison to other configurations.
>
>
>
> In general, there appears to be some benefit to be gained in a couple of
> the benchmarks (spec2000/art, spec2006/milc) by postponing vectorization.
>
>
>
> I just wanted to present this information to the community to see if there
> is interest in pursuing the idea of postponing passes.
>
>
>
> Daniel
>
>
>
> *From:* llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] *On
> Behalf Of *Daniel Stewart
> *Sent:* Wednesday, September 17, 2014 9:46 AM
> *To:* llvmdev at cs.uiuc.edu
> *Subject:* [LLVMdev] Postponing more passes in LTO
>
>
>
> Looking at the existing flow of passes for LTO, it appears that most all
> passes are run on a per file basis, before the call to the gold linker. I’m
> looking to get people’s feedback on whether there would be an advantage to
> waiting to run a number of these passes until the linking stage. For
> example, I believe I saw a post a little while back about postponing
> vectorization until the linking stage. It seems to me that there could be
> an advantage to postponing (some) passes until the linking stage, where the
> entire graph is available. In general, what do people think about the idea
> of a different flow of LTO where more passes are postponed until the
> linking stage?
>
>
>
> Daniel Stewart
>
>
>
> --
>
> Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted
> by The Linux Foundation
>
>
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20141218/0722cd86/attachment.html>


More information about the llvm-dev mailing list