From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 92058 invoked by alias); 2 Feb 2018 19:23:31 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 92046 invoked by uid 89); 2 Feb 2018 19:23:31 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy= X-HELO: gate.crashing.org Received: from gate.crashing.org (HELO gate.crashing.org) (63.228.1.57) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 02 Feb 2018 19:23:30 +0000 Received: from gate.crashing.org (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id w12JNR6G016521; Fri, 2 Feb 2018 13:23:27 -0600 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id w12JNQAa016520; Fri, 2 Feb 2018 13:23:26 -0600 Date: Fri, 02 Feb 2018 19:23:00 -0000 From: Segher Boessenkool To: gcc-patches@gcc.gnu.org, richard.sandiford@linaro.org Subject: Re: Fix LRA subreg calculation for big-endian targets Message-ID: <20180202192326.GK21977@gate.crashing.org> References: <87inbopx9c.fsf@linaro.org> <20180131162833.GP21977@gate.crashing.org> <87shal4zl9.fsf@linaro.org> <87607fa31k.fsf@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87607fa31k.fsf@linaro.org> User-Agent: Mutt/1.4.2.3i X-IsSubscribed: yes X-SW-Source: 2018-02/txt/msg00129.txt.bz2 On Fri, Feb 02, 2018 at 02:17:59PM +0000, Richard Sandiford wrote: > Richard Sandiford writes: > > Segher Boessenkool writes: > >> On Fri, Jan 26, 2018 at 01:25:51PM +0000, Richard Sandiford wrote: > >>> if (SCALAR_INT_MODE_P (inmode)) > >>> new_out_reg = gen_lowpart_SUBREG (outmode, reg); > >>> else > >>> - new_out_reg = gen_rtx_SUBREG (outmode, reg, 0); > >>> + { > >>> + poly_uint64 offset = subreg_lowpart_offset (outmode, inmode); > >>> + new_out_reg = gen_rtx_SUBREG (outmode, reg, offset); > >>> + } > >> > >> Is this now not exactly the same as the SCALAR_INT_MODE_P case? The mode > >> of "reg" is inmode, after all? > > > > Bah, yes. Don't know how I missed that. :-( I think I must have > > been reading it as SCALAR_INT_P, and thinking this was some weird > > VOIDmode thing. > > > > Will fix. > > Like so. Tested as before. OK to install? Looks good to me, fwiw. Segher