This is the mail archive of the 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: [BENCH] Improvements to popping x87 stack in reg-stack.c

Hi Uros,
On Mon, 29 Nov 2004, Uros Bizjak wrote:
> I have some benchmark numbers for povray-3.50c, with your patch for
> reg-stack.c.


> Unpatched povray:
> grep fxch povray | wc -l
>   15648
> Patched povray:
> grep fxch bbb | wc -l
>   15659

This observed increase in the number of fxch instructions is likely
another side-effect of reg-stack's lack of stack planning.  Currently
most stacks are assigned in an "arbitrary permutation" left over from
the previous block.  We've now altered this arbitrary random permutation,
so some basic blocks may see an increase in shuffling and others will
see a decrease.  The compensation code on edges, though, is always

As I mentioned in a previous e-mail, I doubt there's anything that
can be done about this existing deficiency in gcc's 4.0 timeframe.
Indeed, the negligible performance improvements of my patch, would
appear to also make it unsuitable for 4.0.

> that double pop can be implemented using fcompp instruction
> (pentopt.pdf, page 126, section 19.1). As your patch groups FFREEs
> together, perhaps they can be implemented in the recommended way
> with fcompp?

This further optimization is certainly easier to implement following
this round of changes.


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