Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Cc: rhill@g.o
Subject: Re: [gentoo-dev] LTO use in the tree
Date: Mon, 21 Apr 2014 06:54:10
Message-Id: 20140421085344.116d1ff9@pomiot.lan
In Reply to: [gentoo-dev] LTO use in the tree by Ryan Hill
1 Dnia 2014-04-20, o godz. 21:14:51
2 Ryan Hill <rhill@g.o> napisał(a):
3
4 > As more and more packages are starting to add LTO flags automatically through
5 > their build systems, I thought I'd point out a couple things:
6 >
7 > - LTO utterly destroys debug info. Flags like -g are incompatible with LTO.
8 >
9 > - LTO causes .GCC.command.line sections to be discarded, which means your
10 > package will always be QA flagged as ignoring CFLAGS.
11 >
12 > - LTO takes a _lot_ of memory. That memory is required on the host arch.
13 > Distcc doesn't help things here, because linking happens locally. Consider
14 > all the archs your package is built on, and if they all routinely have
15 > multiple GBs of memory installed.
16
17 Those are the reasons why I have disabled the default -flto in systemd.
18 For other packages based on systemd configure macros, it can be
19 disabled via the following configure hack:
20
21 cc_cv_CFLAGS__flto=no
22
23 --
24 Best regards,
25 Michał Górny

Attachments

File name MIME type
signature.asc application/pgp-signature