ACCUMULATE_OUTGOING_ARGS and the i386
Joe Buck
jbuck@synopsys.com
Mon Oct 19 02:16:00 GMT 1998
> > What are the tradeoffs involved in ACCUMULATE_OUTGOING_ARGS? Why
> > would I not want to implement it for the i386?
Jeff writes:
> Plusses:
>
> Stack pointer stays constant...
> A constant stack pointer makes it a lot easier for gdb to grok frame
> pointerless code. This may make it possible to turn on frame pointer
> elimination by default.
>
> 1. More efficient prologues & epilogues.
> 2. The compiler gets to use another register.
It seems that #2 would be a big win on the register-poor i386
architecture. Also, overhead for C++ exceptions should be reduced
substantially, right?
> Minuses:
>
> If the architecture has push insns and they're smaller/faster than
> using reg+d addresses, then ACCUMULATE_OUTGOING_ARGS may be a lose due
> to the increased cost to save arguments into the stack. Depends on the
> relative costs.
Given the other factors, this increased cost might be outweighed by
the benefits, but of course this would have to be measured. I suspect
that a push might even be slower on the new processors if there are
many separate stack adjustments, but I'm far from an x86 guru.
More information about the Gcc
mailing list