This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: fix pr23303
- From: Paolo Bonzini <paolo dot bonzini at lu dot unisi dot ch>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>, Richard Henderson <rth at redhat dot com>,Steven Bosscher <stevenb at suse dot de>
- Date: Fri, 09 Sep 2005 22:49:37 +0200
- Subject: Re: fix pr23303
- References: <43219DDE.6060002@lu.unisi.ch> <20050909195532.GB22934@redhat.com>
> Ok for mainline?
No.
"The patch saves about 15% of compilation time for tramp3d with profiling
as all those tons of counters increments can now be direct. It also
seems to have relatively positive effect on SPEC ..."
Let me say that this patch only affects !TARGET_READ_MODIFY targets, and
Honza most likely did not test these (Pentium/PPro), but an AMD target.
However I won't defend the patch much further than this, because there
are a lot of places in the RTL optimization pipeline that could modify
the instructions so that the peephole2 triggers and the leal is not
emitted. For example, combine could decide to create a (plus (reg)
(mem)) rather than a (plus (ashift (reg) (const_int 2)) (reg)). It
could actually be just luck that a leal was produced in 4.0 or earlier
compilers.
Paolo