simplify_plus_minus busted in 4.3

Bernd Schmidt bernds_cb1@t-online.de
Wed Feb 11 14:56:00 GMT 2009


Paolo Bonzini wrote:
> Paolo Bonzini wrote:
>> Bernd Schmidt wrote:
>>> While trying to teach the doloop code new tricks in our Blackfin tree
>>> based on 4.3, I've noticed that simplify_plus_minus appears to be
>>> busted.
>> I will try on 4.4 and let you know.  I remember some fixes going in for
>> s_p_m; all of them could be backported to your tree, even though some
>> were unsafe for other targets (they depended on using UNSPECs rather
>> than MINUSes for things such as PIC access).
> 
> Here it is (extracted from r142035).  In
> http://gcc.gnu.org/ml/gcc-patches/2008-11/msg00792.html Zdenek said
> "simplify-rtx.c:simplify_plus_minus may fail before it actually tries to
> simplify the expression, so it may e.g. leave (x+y)-y unsimplified" and
> that seems exactly your case).
> 
> As I said in the previous email, it is safe for Blackfin even though I
> am not sure it would be okay for the FSF 4.3 tree.

It's a regression, and it does affect code generation in a few cases
I've seen.  So I'd like approval to apply either Paolo's patch or my
earlier one to the 4.3 tree after testing.


Bernd
-- 
This footer brought to you by insane German lawmakers.
Analog Devices GmbH      Wilhelm-Wagenfeld-Str. 6      80807 Muenchen
Sitz der Gesellschaft Muenchen, Registergericht Muenchen HRB 40368
Geschaeftsfuehrer Thomas Wessel, William A. Martin, Margaret Seif



More information about the Gcc-patches mailing list