From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4233 invoked by alias); 23 Nov 2014 07:27:35 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 4222 invoked by uid 89); 23 Nov 2014 07:27:35 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Sun, 23 Nov 2014 07:27:33 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 31C0A1167D8; Sun, 23 Nov 2014 02:27:32 -0500 (EST) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id b1yAOfDQeg6C; Sun, 23 Nov 2014 02:27:32 -0500 (EST) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id C46611167CF; Sun, 23 Nov 2014 02:27:31 -0500 (EST) Received: by joel.gnat.com (Postfix, from userid 1000) id DEF1B40F79; Sun, 23 Nov 2014 11:27:30 +0400 (RET) Date: Sun, 23 Nov 2014 07:27:00 -0000 From: Joel Brobecker To: Sandra Loosemore Cc: gdb-patches@sourceware.org Subject: Re: GCC switch to C11 causes many testsuite compiler diagnostics Message-ID: <20141123072730.GB7136@adacore.com> References: <544BD7E6.1050602@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <544BD7E6.1050602@codesourcery.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2014-11/txt/msg00555.txt.bz2 > Comparing my latest nios2 test results (with Pedro's thread patch) > with those from a checkout a couple weeks old, I noticed I had some > new ERRORs due to apparent compilation failures. I tracked this > down to the recent change on GCC mainline (r216247) to make the > default C dialect GNU11, which enables -Wimplicit-int and > -Wimplicit-function-declaration by default. I started working on a > patch to fix the offending testcases, but realized that there are > hundreds of them. :-( > > So, before I invest a lot more time on this, is updating the GDB > testsuite to use a more modern C dialect the Right Thing To Do? I'm > also wondering if it's really necessary to support compilers that > can't handle function prototypes in the testsuite (not defining > PROTOTYPES seems to be the default, in fact). Generally speaking, I don't see a problem with modifying the code in testcases to conform to the new warnings, but we need to verify that it does not undo something that was specifically done for that testcase. Perhaps what we could do instead, is look at compiling the code with switches that turn those off by default in the testsuite directory? (I think this could be done in gdb_compile?) Not completely obvious, but perhaps less time-consuming and boring than doing mechanical updates of a lot of testcases... Before you go ahead and implement anything, you might want to wait to see what others think of the idea. I wouldn't say that this is obviously the best compromise... -- Joel