This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Optimising for size


Just a tentative question about a problem:

I have a piece of C code. The code, compiled to an ARM THUMB target using
gcc 4.0.2, with -Os results in 230 instructions. The exact same code,
using the exact same switches compiles to 437 instructions with gcc 4.3.1.
Considering that the compiler optimises to size and the much newer
compiler emits almost twice as much code as the old one, I think it is an
issue.

So the question is, how should I report it? It is not a bug as such, it is
a performance issue, but I think one that should be considered. Overall on
a source resulting in a 4000 insns long binary the newer version compiles
only about 150 instructions more than the old one, indicating that it
actually saved some space on pieces of the code other than the above
mentioned very sick case, but the savings wasn't enough to compensate for
the 230 -> 437 instruction blowout.

Thanks,

Zoltan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]