This is the mail archive of the gcc-patches@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]

Re: [Patch,AVR]: Fix PR52488 (insane stack usage)


2012/3/12 Georg-Johann Lay <avr@gjlay.de>
>
> ...and now to the right mailing list...
>
> This patch cuts down insane stack offsets for 8-bit SP targets to a value
> the
> involved insns can handle.
>
> Background is that newlib generates such insane offsets (2050 bytes of
> stack
> for a device with 128 bytes of RAM) because of extension PR51345, i.e. new
> multilib variants for 8-bit SP targets.
>
> The CFA notes still contain the original size as requested by the source
> so
> that -Wstack-usage= will still work as intended.
>
> The generated code will never be functional, of course, but there should
> never
> be an ICE.
>
> This patch is less aggressive than the patch proposed in the PR, i.e. it
> is
> silent and does not issue an error so that newlib can still be built. If
> the
> user wants additional sanity checking, he has to use -Wstack-usage= or
> similar
> options.
>
> Passed testsuite.
>
> Ok for trunk?
>
> Johann
>
> Â Â Â ÂPR target/52488
> Â Â Â Â* config/avr/avr.c (avr_prologue_setup_frame): Cut down stack
> Â Â Â Âoffset (size) to a value the insns can deal with.
> Â Â Â Â(expand_epilogue): Ditto.
>

Approved.

Denis.


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