[tree-ssa] more experiments with disabling RTL passes for tree-ssa

Steven Bosscher stevenb@suse.de
Tue Apr 6 21:47:00 GMT 2004


Hi,

As a follow-up to the flags changes I suggested last weekend,
I SPEC tested the attached patch and got better performance
results than the ones I posted, while compile time is still
a _lot_ faster than tree-ssa unpatched.  Diego, you may want
to try this instead of the flags you run now.

Dan Berlin also suggested we should try to run GCSE as if we're
optimizing for size, but I didn't do this now.  I did find out
that completely disabling GCSE has adverse effects on perlbmk,
gap, and vortex, but many other benchmarks (gzip, vpr) have 
worse results with GCSE enabled.  This is something worth
investigating because compile time with GCSE disabled is ~6%
better...

The patch does the following:
- Disable a bunch of pre-reload expensive optimizations by
  commenting them out.  I left expensive alias analysis and
  stack slot combining enabled because they probably are
  still useful.
- Disable RTL jump threading, because Jeff suggested a while
  ago that it is mostly (completely?) subsumed by DOM.
- Disable flag_cse_follow_jumps, flag_cse_skip_blocks, and
  flag_delete_null_pointer_checks.  These should also be
  subsumed by tree-ssa.

Right now I've disabled these passes with hard-coded zeros
and an "#if 0", but that is inconvenient.  We need some way to
test tree-ssa without RTL passes to find out which ones are not
very effective anymore, but coding them out like this means we
cannot test them anymore at all.  There are still some things
that RTL passes do and tree-ssa passes miss (hi Kazu, nice job!),
so it would be nice IMO to have the ability to test the compiler
with those passes enabled.

So I'd like to propose an -fenable-old-rtl-passes flag that we
may use to disable some of the RTL passes after the merge.
That way, Kazu can go on haunting Diego  :-)

Gr.
Steven

	* cse.c (find_best_addr, cse_insn): Don't do expensive
	optimizations.
	* expmed.c (emit_store_flag): Always try to reuse the same pseudo,
	even when doing expensive optimizations.
	* stmt.c (preserve_subexpressions_p): Don't always preserve when
	doing expensive optimizations.
	* passes.c (rest_of_handle_gcse): Don't run CSE after GCSE.
	* opts.c (decode_options): Don't enable RTL jump threading at -O.
	Don't enable CSE path following and block skipping at -O2.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch
Type: text/x-diff
Size: 7106 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20040406/ca075c47/attachment.bin>


More information about the Gcc mailing list