Gentoo Archives: gentoo-user

From: Rasmus Thomsen <Rasmus.thomsen@××××××××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] world rebuild with gcc-6.3.0 - not completely there yet
Date: Sun, 14 May 2017 09:22:53
Message-Id: 5FvWyst2mo67uZtwj20Cz62EWZoCg9b_3SuINoCa_24OGSixLCbZOQHvCpz29bC9fQeLOrAhffVddD4AO79SLqNxoJXawbF_jIXAKmTbIKU=@protonmail.com
In Reply to: Re: [gentoo-user] world rebuild with gcc-6.3.0 - not completely there yet by Walter Dnes
1 Hi,
2
3 unwind tables sounds really interesting, but does it affect the binary size when I compile with -O2 anyway?
4
5 Regards,
6 Rasmus
7
8 -------- Original Message --------
9 On 14 May 2017, 07:13, Walter Dnes wrote:
10 On Sat, May 13, 2017 at 10:21:19AM +0200, Helmut Jarausch wrote
11 >
12 > I have switched to gcc-6.3.0 at the end of last year.
13 > I have (re-)compiled all my packages including icewm-1.3.12-r1.
14 > Everything works just fine.
15 >
16 > I did have some segfaults (with gimp) until I recompiled each package
17 > with gcc-6.3.0
18 >
19 > I have
20 > CFLAGS="-mtune=native -O2 -msse3 -pipe -fPIC"
21 >
22 > in /etc/portage/make.conf
23
24 Why aren't you running "-march=native"? You're probably missing quite
25 a few features of your cpu. BTW, "-march=native" implies "-mtune=native"
26 and "-msse3" (if the cpu supports it). Out of sheer curiousity, what
27 does gcc report as your native cpu when you run...
28
29 gcc -c -Q -march=native --help=target | grep march=
30
31 > and quite a e few
32 > CFLAGS="-O3 -mtune=native -pipe -msse -msse2 -msse3 -msse4a -m3dnow"
33 > (for my aged AMD64 Phenom II machine)
34 >
35 > in /etc/portage/env/...
36
37 "-O3"... yikes! Not really recommended. If you want speedup, use
38 "-march=native" instead.
39
40 In make.conf, I have...
41
42 CFLAGS="-O2 -march=native -mfpmath=sse -fomit-frame-pointer -pipe -fno-unwind-tables -fno-asynchronous-unwind-tables"
43
44 The 2 "unwind_tables" flags reduce code bloat. See
45 http://comments.gmane.org/gmane.linux.busybox/36695 for details. The
46 guys at busybox do what they can to reduce code bloat. Knocking 15% off
47 the size of an executable or library helps. This results in faster
48 loading at startup (less to load), and less stuff in ram cuts down on
49 swapping.
50
51 --
52 Walter Dnes <waltdnes@××××××××.org>
53 I don't run "desktop environments"; I run useful applications

Replies

Subject Author
Re: [gentoo-user] world rebuild with gcc-6.3.0 - not completely there yet Walter Dnes <waltdnes@××××××××.org>