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

[GCC 4.2 Project] Replacements for CSE path following



This pass does simple forward propagation and simplification when an operand of an insn can only come from a single def. The pass has a very good potential of catching simplifications currently done by inter-basic-block CSE (-fcse-follow-jumps and -fcse-skip-blocks) and combine: however, it is much faster than inter-basic-block CSE and runs much earlier than combine.


Unlike other attempts to supersede CSE path following, however, I did not write a general optimization framework like GCSE: instead, looking at what kinds of simplifications are only made by CSE, I tried to implement them in a very generic way. Take for example Bug 13724: my fix for it was to make CSE recognize the high word of (zero_extend:DI (reg:SI M)), and simplify it to zero. After committing it, Roger Sayle also tried adding the same to simplify-rtx.c, but it was ineffective. This pass, instead, can use simplify-rtx.c much more effectively than CSE.

The patch currently has performance regressions in mesa and in crafty, but overall slightly improves SPEC with a saving of 2-3% in bootstrap and compilation time.

Personnel

* Paolo Bonzini

Delivery Date

Stage 1

I actually hoped that the pass itself can go in 4.1, being disabled by default, but it seems unlikely at this point.

Benefits

Improved compilation time, incentive for moving optimizations from combine.c to simplify-rtx.c.

Dependencies

* None.

Modifications Required

The regressions are still to be investigated; but most of the modifications will most likely be in simplify-rtx.c (pouring simplifications in there from combine), or may involve more sophisticated analysis of available expressions in the forward propagation pass.


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