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

[Bug middle-end/66588] combine should try transforming if_then_else of zero_extends into zero_extend of if_then_else


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66588

Segher Boessenkool <segher at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |segher at gcc dot gnu.org

--- Comment #4 from Segher Boessenkool <segher at gcc dot gnu.org> ---
combine should not in general try multiple ways to write the same
thing; this will not scale.  In this case, I don't see that some
backends would really like to write it one way and some the other,
so we should just use one way.

There are no defined canonicalization rules for this, but there
are for the similar cases involving MULT, where the extends are
moved inwards as well.  This is most in line with how other extends
are treated as well.

We probably should document the canonicalization rules better;
current practice for backends is to just look at what combine does
and use that; not a great idea in my opinion.


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