Bug 41633 - -Wframe-larger-than should warn about outgoing function calls, specifically varargs
Summary: -Wframe-larger-than should warn about outgoing function calls, specifically v...
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: unknown
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
Depends on:
Reported: 2009-10-08 18:57 UTC by Frank Ch. Eigler
Modified: 2010-11-05 18:12 UTC (History)
2 users (show)

See Also:
Known to work:
Known to fail:
Last reconfirmed: 2010-11-05 18:12:22


Note You need to log in before you can comment on or make changes to this bug.
Description Frank Ch. Eigler 2009-10-08 18:57:51 UTC
gcc should warn when the stack frame for a called varargs function
is in excess of a -Wframe-larger-than=NNN bytes.  Such a check could
be done at each call site, to see whether the outgoing arguments
alone already exhaust NNN.
Comment 1 Frank Ch. Eigler 2009-11-02 16:43:28 UTC
Please be aware that the linux kernel uses this flag in its builds
as a tool to help limit runtime stack consumption, as a safety/security
matter.  So it goes beyond a "nice to have".
Comment 2 Frank Ch. Eigler 2010-11-05 18:12:22 UTC
Still present as of gcc 4.5.