ARM: turn on link time optimisation (LTO).

Suggested by @Wurstnase. Apparently gcc got better, so it's
actually an advantage now.

Actually a pretty big advantage. While binary size decreases some
200 bytes, pulse length of the debug LED is a lot shorter
(measured on the scope):

  without LTO:  4.59 us
  with LTO:     3.65 us

That's a 25% performance increase by just turning on a flag!
This commit is contained in:
Markus Hitter 2016-12-07 11:21:13 +01:00
parent 39f66ef6b0
commit 877b9fae6f
1 changed files with 1 additions and 1 deletions

View File

@ -107,7 +107,7 @@ endif
CFLAGS += -Wall
CFLAGS += -Wstrict-prototypes
CFLAGS += -Os
#CFLAGS += -flto
CFLAGS += -flto
CFLAGS += -ffunction-sections
CFLAGS += -fdata-sections
#CFLAGS += -dM -E # To list all predefined macros into the .o file.