On 15/05/18 22:03, Freddie Chopin wrote:

> 
> I cannot reproduce this here ); Don't get me wrong - if there's a
> "free" way to improve code size/speed with some compiler flags which I
> did not use previously, then I'm very much interested, however in my
> particular case the best result (size-wise) I get is with just
> -ffunction-sections + -fdata-sections. The difference is not huge, but
> it's also not negligible. Maybe this has to do with different compiler
> versions we are comparing (4.8 vs 8.1)? I guess this is not LTO (which
> I did not enable for these measurements), as you did not mention it in
> your flags...
> 

It is quite possible that the difference is from the gcc versions -
there have been many improvements since 4.8, and it is entirely possible
that gcc now gives the benefits of -fsection-anchors even with
-fdata-sections.  And I was looking here at the differences for short
code sections, rather than the whole program.

I will try a few more tests when I have the chance.  This computer has
such an old Linux installation that I can no longer use modern pre-built
versions of the gnu arm embedded toolchain - I can't even use
godbolt.org because the browser version is too old.  I'll test from
home, where I have newer arm gcc versions (including a "bleeding edge"
toolchain or too, provided by some nice chap off the internet :-) ).



Reply via email to