From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15938 invoked by alias); 7 Mar 2011 19:52:23 -0000 Received: (qmail 15924 invoked by uid 22791); 7 Mar 2011 19:52:22 -0000 X-SWARE-Spam-Status: No, hits=-4.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_HK_NAME_DR,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 07 Mar 2011 19:52:17 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p27Jq8sW021199 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 7 Mar 2011 14:52:09 -0500 Received: from rivendell.middle-earth.co.uk ([10.3.113.4]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p27Jq4jU026119 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Mon, 7 Mar 2011 14:52:07 -0500 Date: Mon, 07 Mar 2011 19:52:00 -0000 From: Dr Andrew John Hughes To: "Joseph S. Myers" Cc: Jim Meyering , gcc-patches@gcc.gnu.org, java-patches@gcc.gnu.org Subject: Re: avoid useless if-before-free tests Message-ID: <20110307195204.GL9339@rivendell.middle-earth.co.uk> References: <87zkp9zmq0.fsf@rho.meyering.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Mailing-List: contact java-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-patches-owner@gcc.gnu.org X-SW-Source: 2011-q1/txt/msg00048.txt.bz2 On 19:16 Sat 05 Mar , Joseph S. Myers wrote: > On Sat, 5 Mar 2011, Jim Meyering wrote: > > > diff --git a/gcc/config/i386/gmm_malloc.h b/gcc/config/i386/gmm_malloc.h > > index 7a7e840..8993fc7 100644 > > --- a/gcc/config/i386/gmm_malloc.h > > +++ b/gcc/config/i386/gmm_malloc.h > > @@ -67,8 +67,7 @@ _mm_malloc (size_t size, size_t align) > > static __inline__ void > > _mm_free (void * aligned_ptr) > > { > > - if (aligned_ptr) > > - free (((void **) aligned_ptr) [-1]); > > + free (((void **) aligned_ptr) [-1]); > > } > > This one looks suspicious; it's not if (p) free (p); but if (p) free > (something-derived-from-p);. > > > diff --git a/libjava/classpath/native/fdlibm/dtoa.c b/libjava/classpath/native/fdlibm/dtoa.c > > index 458e629..92aa793 100644 > > http://gcc.gnu.org/codingconventions.html says Classpath changes should go > via Classpath upstream, not directly into GCC. I don't know if that's > still accurate. > That's still true. This seems to be the first message I've received in this thread, so I'm not even aware of what these changes are. Were the earlier messages not sent to this list? > > diff --git a/zlib/contrib/minizip/unzip.c b/zlib/contrib/minizip/unzip.c > > index 9ad4766..644ef1b 100644 > > We definitely don't want to make local changes to zlib for this sort of > issue, though importing a new upstream version of zlib (making sure the > local configure code still works) should be fine for 4.7. > > -- > Joseph S. Myers > joseph@codesourcery.com -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: F5862A37 (https://keys.indymedia.org/) Fingerprint = EA30 D855 D50F 90CD F54D 0698 0713 C3ED F586 2A37