From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 08 15:08:53 2011 Received: (at submit) by debbugs.gnu.org; 8 Aug 2011 19:08:53 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QqVBz-0005BT-2K for submit@debbugs.gnu.org; Mon, 08 Aug 2011 15:08:52 -0400 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QqVBs-0005BF-HZ for submit@debbugs.gnu.org; Mon, 08 Aug 2011 15:08:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QqVAd-0004LX-W9 for submit@debbugs.gnu.org; Mon, 08 Aug 2011 15:07:31 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=unavailable version=3.3.1 Received: from lists.gnu.org ([140.186.70.17]:57285) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QqVAd-0004L4-Sb for submit@debbugs.gnu.org; Mon, 08 Aug 2011 15:07:27 -0400 Received: from eggs.gnu.org ([140.186.70.92]:51175) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QqUyr-0004d5-7C for bug-coreutils@gnu.org; Mon, 08 Aug 2011 14:55:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QqUyp-0001sb-Ti for bug-coreutils@gnu.org; Mon, 08 Aug 2011 14:55:17 -0400 Received: from smtp.cs.ucla.edu ([131.179.128.62]:33088) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QqUyp-0001rR-KT for bug-coreutils@gnu.org; Mon, 08 Aug 2011 14:55:15 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id 1C73B39E80F7 for ; Mon, 8 Aug 2011 11:55:13 -0700 (PDT) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8gronudNgDLl for ; Mon, 8 Aug 2011 11:55:12 -0700 (PDT) Received: from [10.1.205.231] (206-169-234-26.static.twtelecom.net [206.169.234.26]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 04EB639E80DA for ; Mon, 8 Aug 2011 11:55:11 -0700 (PDT) Message-ID: <4E403108.5090301@cs.ucla.edu> Date: Mon, 08 Aug 2011 11:55:04 -0700 From: Paul Eggert User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.18) Gecko/20110617 Thunderbird/3.1.11 MIME-Version: 1.0 To: bug-coreutils@gnu.org Subject: test.c runs afoul of GCC 4.6.1 bug if --enable-gcc-warnings Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.17 X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.5 (----) I'm running into a problem with GCC 4.6.1 x86-64 when compiling coreutils (latest git version), configured with --enable-gcc-warnings. A bogus warning is generated, causing "make" to fail. The warning is "function might be candidate for attribute 'pure' if it is known to return normally [-Wsuggest-attribute=pure]", and it points to the "advance" function in test.c. The warning is also generated for lbracket.c, which includes test.c. This is due to a GCC bug that has just been confirmed; see . For now I'm leaving this alone, but I thought I'd give others a heads-up. The coreutils code is pretty crufty but on the other hand I dislike modifying code just to work around bugs in static checkers. From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 08 17:11:56 2011 Received: (at 9262) by debbugs.gnu.org; 8 Aug 2011 21:11:56 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QqX75-0008CQ-Ft for submit@debbugs.gnu.org; Mon, 08 Aug 2011 17:11:56 -0400 Received: from mx.meyering.net ([82.230.74.64]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QqX72-0008CH-SD for 9262@debbugs.gnu.org; Mon, 08 Aug 2011 17:11:54 -0400 Received: from rho.meyering.net (localhost.localdomain [127.0.0.1]) by rho.meyering.net (Acme Bit-Twister) with ESMTP id 02AA16005B; Mon, 8 Aug 2011 23:10:47 +0200 (CEST) From: Jim Meyering To: Paul Eggert Subject: Re: bug#9262: test.c runs afoul of GCC 4.6.1 bug if --enable-gcc-warnings In-Reply-To: <4E403108.5090301@cs.ucla.edu> (Paul Eggert's message of "Mon, 08 Aug 2011 11:55:04 -0700") References: <4E403108.5090301@cs.ucla.edu> Date: Mon, 08 Aug 2011 23:10:47 +0200 Message-ID: <87wren8v8o.fsf@rho.meyering.net> Lines: 38 MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: 9262 Cc: 9262@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) Paul Eggert wrote: > I'm running into a problem with GCC 4.6.1 x86-64 when > compiling coreutils (latest git version), configured > with --enable-gcc-warnings. A bogus warning is generated, > causing "make" to fail. The warning is "function might be > candidate for attribute 'pure' if it is known to return > normally [-Wsuggest-attribute=pure]", and it points to the > "advance" function in test.c. The warning is also generated > for lbracket.c, which includes test.c. > > This is due to a GCC bug that has just been confirmed; see > . > > For now I'm leaving this alone, but I thought I'd give > others a heads-up. The coreutils code is pretty > crufty but on the other hand I dislike modifying code just > to work around bugs in static checkers. Thanks for the heads up. This came up in July: http://thread.gmane.org/gmane.comp.gnu.coreutils.general/1399 This is why I now build with gcc-4.7.x. With it, I no longer get that invalid warning. Ideally, configure would check for the buggy compiler and disable the offending option when found. If you're not going to work on that, what do you think about sending a message to control@debbugs.gnu.org with this in the body? tags 9262 + notabug close 9262 Since this isn't a bug in coreutils, and I'm trying to close issues we're not likely to work on. From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 09 00:16:13 2011 Received: (at control) by debbugs.gnu.org; 9 Aug 2011 04:16:13 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Qqdjg-0000xZ-Hl for submit@debbugs.gnu.org; Tue, 09 Aug 2011 00:16:13 -0400 Received: from smtp.cs.ucla.edu ([131.179.128.62]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Qqdjd-0000xQ-Ar for control@debbugs.gnu.org; Tue, 09 Aug 2011 00:16:10 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id 99E0339E8106 for ; Mon, 8 Aug 2011 21:15:02 -0700 (PDT) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7TblC2OsYgNj for ; Mon, 8 Aug 2011 21:15:02 -0700 (PDT) Received: from [10.1.205.231] (206-169-234-26.static.twtelecom.net [206.169.234.26]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 3354139E80F8 for ; Mon, 8 Aug 2011 21:15:02 -0700 (PDT) Message-ID: <4E40B43F.1020904@cs.ucla.edu> Date: Mon, 08 Aug 2011 21:14:55 -0700 From: Paul Eggert User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.18) Gecko/20110617 Thunderbird/3.1.11 MIME-Version: 1.0 To: control@debbugs.gnu.org Subject: closing as a bug in GCC, not in coreutils Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Spam-Score: -3.0 (---) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.0 (---) tags 9262 + notabug close 9262 From unknown Fri Jun 20 07:24:18 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 06 Sep 2011 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator