This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Implement -fstack-usage
Eric Botcazou <ebotcazou@adacore.com> writes:
> > Why do we require targetm.get_static_stack_usage to be defined?
> > Clearly it's necessary for precise results. But we can get pretty
> > good results just by calling get_frame_size. Is there any reason to
> > enforce this restriction?
>
> Define "pretty good results". Do not forget that the goal is to give a
> conservative estimate in all cases.
It seems to me that a conservative default would be get_frame_size
plus the sizes of all the live callee saved hard registers plus some
slop.
Ian