From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14647 invoked by alias); 23 Jun 2011 13:14:25 -0000 Received: (qmail 14635 invoked by uid 22791); 23 Jun 2011 13:14:24 -0000 X-SWARE-Spam-Status: No, hits=-1.2 required=5.0 tests=AWL,BAYES_00,KAM_ADVERT2,NO_DNS_FOR_FROM,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mga09.intel.com (HELO mga09.intel.com) (134.134.136.24) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 23 Jun 2011 13:14:10 +0000 Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 23 Jun 2011 06:14:09 -0700 X-ExtLoop1: 1 Received: from gnu-6.sc.intel.com ([10.3.194.135]) by orsmga002.jf.intel.com with ESMTP; 23 Jun 2011 06:14:09 -0700 Received: by gnu-6.sc.intel.com (Postfix, from userid 500) id C47C4C0498; Thu, 23 Jun 2011 06:14:07 -0700 (PDT) Date: Thu, 23 Jun 2011 14:08:00 -0000 From: "H.J. Lu" To: gcc-patches@gcc.gnu.org Subject: Re: PATCH: PR rtl-optimization/49504: Invalid optimization for Pmode != ptr_mode Message-ID: <20110623131407.GA17824@intel.com> Reply-To: "H.J. Lu" References: <20110622193657.GA8942@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110622193657.GA8942@intel.com> User-Agent: Mutt/1.5.21 (2010-09-15) 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 X-SW-Source: 2011-06/txt/msg01759.txt.bz2 On Wed, Jun 22, 2011 at 12:36:57PM -0700, H.J. Lu wrote: > Hi, > > I just don't see how nonzero_bits1 can assume if pointers extend unsigned > and this is an addition or subtraction to a pointer in Pmode, all the bits > bove ptr_mode are known to be zero. We never run into it before x32 > since x32 is the first such target. > > This patch deletes it. OK to install the nonzero_bits1 part for trunk? > > Thanks. > > I checked this patch into x32 branch. H.J. --- commit de145b6ad18327c34009d96f1a1f0a9510023f31 Author: H.J. Lu Date: Thu Jun 23 06:09:20 2011 -0700 Check correct return value. diff --git a/gcc/testsuite/ChangeLog.x32 b/gcc/testsuite/ChangeLog.x32 index 6581a45..cde8d41 100644 --- a/gcc/testsuite/ChangeLog.x32 +++ b/gcc/testsuite/ChangeLog.x32 @@ -1,3 +1,7 @@ +2011-06-23 H.J. Lu + + * gcc.target/i386/pr49504.c (main): Check correct return value. + 2011-06-22 H.J. Lu PR rtl-optimization/49504 diff --git a/gcc/testsuite/gcc.target/i386/pr49504.c b/gcc/testsuite/gcc.target/i386/pr49504.c index 9128196..503e6c2 100644 --- a/gcc/testsuite/gcc.target/i386/pr49504.c +++ b/gcc/testsuite/gcc.target/i386/pr49504.c @@ -12,7 +12,7 @@ foo (const void* p, unsigned long long q) int main () { - if (foo ((const void*) 0x100, 0x100000000ULL) == 0) + if (foo (foo, 0x100000000ULL) != 0x1) __builtin_abort (); return 0; }