GCC-4.1.0 size optimization bug for MIPS architecture...

Richard Henderson rth@redhat.com
Wed Jun 29 09:04:00 GMT 2005


On Tue, Jun 28, 2005 at 11:59:15PM -0500, Steven J. Hill wrote:
> I have discovered what appears to be an optimization bug with '-Os'
> in GCC-4.1.0 for the MIPS architecture. It appears that functions
> which are declared as 'inline' are being ignored and instead turned
> into to function calls ...

Not a bug.  The inline marker is merely suggestive.  You told
the compiler to optimize for size, and it is doing that.

If you absolutely have to have the function inlined, then you
need to use __attribute__((__always_inline__)).


r~



More information about the Gcc mailing list