From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4560 invoked by alias); 1 Sep 2009 02:20:33 -0000 Received: (qmail 4552 invoked by uid 22791); 1 Sep 2009 02:20:32 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail-vw0-f174.google.com (HELO mail-vw0-f174.google.com) (209.85.212.174) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 01 Sep 2009 02:20:26 +0000 Received: by vws4 with SMTP id 4so3303828vws.0 for ; Mon, 31 Aug 2009 19:20:23 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.15.68 with SMTP id j4mr7535960vca.18.1251771623450; Mon, 31 Aug 2009 19:20:23 -0700 (PDT) In-Reply-To: <4A9C4029.2070205@redhat.com> References: <4A9C345E.2030600@redhat.com> <4A9C4029.2070205@redhat.com> Date: Tue, 01 Sep 2009 02:20:00 -0000 Message-ID: Subject: Re: Bit fields From: Jean Christophe Beyler To: Richard Henderson Cc: Ian Lance Taylor , gcc@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-09/txt/msg00002.txt.bz2 On Mon, Aug 31, 2009 at 5:27 PM, Richard Henderson wrote: > On 08/31/2009 02:07 PM, Jean Christophe Beyler wrote: >> >> I am going to try this but shouldn't it be : >> >> (set (reg:QI new-scratch)) >> =A0 =A0 =A0 (zero_extract:DI ...)) > > No. Ok, I think I understand why not: >> (insn 9 8 10 3 struct4.c:24 (set (subreg:DI (reg:QI 76) 0) >> (zero_extract:DI (reg:DI 75) >> (const_int 1 [0x1]) >> (const_int 0 [0x0]))) -1 (nil)) Is basically saying : (set (reg:DI new-scratch) (zero_extract:DI (reg:DI 75) (const_int 1 [0x1]) (const_int 0 [0x0]))) -1 (nil)) and then apply the subreg: (set (reg:QI 76) (subreg:QI (reg:DI new-scratch))) which is what you were saying. I was reading the subreg the other way aroun= d. > >> Any ideas? > > Nope. =A0You'll have to debug it. > Ok, is it normal to see a ashift with a negative value though or is this already sign of a (potentially) different problem? Thanks again and sorry about the random questions, Jc