[patch][plugin,mudflap] Mark builtin alloca as not inlineable

Andrew Pinski pinskia@gmail.com
Sat Jun 20 06:15:00 GMT 2009


On Fri, Jun 19, 2009 at 10:48 PM, Steven Bosscher<stevenb.gcc@gmail.com> wrote:
> On Sat, Jun 20, 2009 at 6:24 AM, Andrew Pinski<pinskia@gmail.com> wrote:
>> alloca should have been marked as not inlinable anyways as it
>> increases the stack usage inside a loop inside a SPEC testcase.
>
> IIRC that was fixed at some point.

No, it still has:
      /* Refuse to inline alloca call unless user explicitly forced so as
         this may change program's memory overhead drastically when the
         function using alloca is called in loop.  In GCC present in
         SPEC2000 inlining into schedule_block cause it to require 2GB of
         RAM instead of 256MB.  */

ok, I looked into this patch and this is not about inlining functions
containing alloca but rather always expanding of alloca inlined.
So really using CALL_CANNOT_INLINE_P is wrong as really it we are
trying to force expanding of alloca inlined in the function.

-- Pinski



More information about the Gcc-patches mailing list