[Cbe-oss-dev] [HACK 1:9] spufs: Workaround gcc (4.1.1) problem with __weak 'empty' functions

Segher Boessenkool segher at kernel.crashing.org
Sat May 31 02:16:22 EST 2008


>>> The compiler is optimizing weak functions that are empty.
>>
>> It considers for inlining all weak functions that are pure
>> functions.
>
> Actually, it has nothing to do with inlining.  (Therefore, -fno-inline
> etc. have no effect whatsoever on this problem!)

Yeah sorry, thinko.  I wanted to point out that this GCC bug can
happen on all pure weak functions, not just empty weak functions,
so the workaround will have to make sure the function isn't pure.

But then I messed up :-)  Thanks for the correction.


Segher




More information about the cbe-oss-dev mailing list