Gentoo Archives: gentoo-dev

From: "C. Bergström" <cbergstrom@×××××××××.com>
To: gentoo-dev@l.g.o
Cc: Martin Vaeth <martin@×××××.de>
Subject: Re: [gentoo-dev] Re: LTO use in the tree
Date: Sun, 27 Apr 2014 00:35:16
Message-Id: 535C507D.9000504@pathscale.com
In Reply to: [gentoo-dev] Re: LTO use in the tree by Martin Vaeth
1 On 04/27/14 02:58 AM, Martin Vaeth wrote:
2 > Rich Freeman <rich0@g.o> wrote:
3 >> FWIW the list of packages I have issues with include:
4 > Not sure whether this is the right place to post it.
5 It's interesting to see that rather lengthy list. From a compiler
6 engineer perspective I'd like to toss in my opinion
7 ---------------------
8 Compiler flags are typically meant to do one or two things. Improve
9 performance or reduce binary (code size). Pragmatically nobody gives a
10 f* if grep has been optimized to the max since it's usually not the
11 bottleneck. Having LTO and whole program optimizations turned on for
12 every package will probably not give you a noticeably faster system, but
13 will certainly slow your build down. (Due to rather large link times)
14
15 The packages which it really *should* be turned on for - anything which
16 is computationally complex, Fortran and stuff where performance matters.
17 I don't know gcc's LTO or what it's capable of, but in our compiler it
18 would also potentially improve large c++ applications a lot. (It should
19 help inline more aggressively and remove c++ layer overhead). In
20 practice though - the most important c++ applications tend to be too
21 huge and end up hitting bugs. They will also typically be very very long
22 link times. (I've seen 30+ minutes - system specs and all things being
23 relative of course..)
24
25 Go ping the gentoo-science guys and get their feedback - they may have
26 the most experience with this...
27 ----------------------
28
29 Not to be a smart-ass, but will someone start a thread on global PGO
30 (profile guided optimizations) next? imho it would be interesting and
31 great to have some general training data already contributed next to the
32 ebuilds. For the science stuff I wouldn't recommend it, but who knows..

Replies

Subject Author
Re: [gentoo-dev] Re: LTO use in the tree Alex Xu <alex_y_xu@×××××.ca>
Re: [gentoo-dev] Re: LTO use in the tree Joshua Kinard <kumba@g.o>
Re: [gentoo-dev] Re: LTO use in the tree Andrew Savchenko <bircoph@×××××.com>