From: Segher Boessenkool Date: Thu, 10 Dec 2015 23:47:31 +0000 (+0100) Subject: rtlanal: Fix bits/bytes confusion in set_noop_p (PR68814) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0c91a1fb3c6bf27bd513d6a160bdce14a7070a60;p=gcc.git rtlanal: Fix bits/bytes confusion in set_noop_p (PR68814) The meaning of ZERO_EXTRACT depends on BITS_BIG_ENDIAN, not on BYTES_BIG_ENDIAN. This caused PR68814. 2015-12-11 Segher Boessenkool PR rtl-optimization/68814 * rtlanal.c (set_noop_p): Use BITS_BIG_ENDIAN instead of BYTES_BIG_ENDIAN. From-SVN: r231547 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 27ccfc8cf72..d6622299cdc 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2015-12-11 Segher Boessenkool + + PR rtl-optimization/68814 + * rtlanal.c (set_noop_p): Use BITS_BIG_ENDIAN instead of + BYTES_BIG_ENDIAN. + 2015-12-10 Nathan Sidwell * config/nvptx/nvptx.c (nvptx_function_arg, diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c index 67098e52ab7..f893bca0d0a 100644 --- a/gcc/rtlanal.c +++ b/gcc/rtlanal.c @@ -1534,7 +1534,7 @@ set_noop_p (const_rtx set) if (GET_CODE (dst) == ZERO_EXTRACT) return rtx_equal_p (XEXP (dst, 0), src) - && ! BYTES_BIG_ENDIAN && XEXP (dst, 2) == const0_rtx + && !BITS_BIG_ENDIAN && XEXP (dst, 2) == const0_rtx && !side_effects_p (src); if (GET_CODE (dst) == STRICT_LOW_PART)