From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 103670 invoked by alias); 23 May 2019 22:26:46 -0000 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 Received: (qmail 103659 invoked by uid 89); 23 May 2019 22:26:46 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=Ryan's, luoxhu, H*f:sk:a16c80d, Ryans X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 23 May 2019 22:26:44 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=svr-ies-mbx-01.mgc.mentorg.com) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1hTwAW-0002IT-8r from joseph_myers@mentor.com ; Thu, 23 May 2019 15:26:36 -0700 Received: from digraph.polyomino.org.uk (137.202.0.90) by svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Thu, 23 May 2019 23:26:32 +0100 Received: from jsm28 (helo=localhost) by digraph.polyomino.org.uk with local-esmtp (Exim 4.90_1) (envelope-from ) id 1hTwAS-0007SC-8v; Thu, 23 May 2019 22:26:32 +0000 Date: Thu, 23 May 2019 22:26:00 -0000 From: Joseph Myers To: Jeff Law CC: luoxhu , , , , , Xiong Hu Luo Subject: Re: *Ping* Re: [PATCH] PR c/43673 - Incorrect warning in dfp printf. In-Reply-To: Message-ID: References: <1551143599-26436-1-git-send-email-luoxhu@linux.ibm.com> <74cee031-3bb8-9356-f7ea-13755159d7f6@linux.ibm.com> <51edfcaf-aaee-b07c-94cd-1a067ce99ba6@linux.ibm.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-SW-Source: 2019-05/txt/msg01634.txt.bz2 On Tue, 21 May 2019, Jeff Law wrote: > On 5/20/19 6:56 PM, luoxhu wrote: > > Ping for GCC-10. > I thought this was a NAK in its current form. > > See Ryan's c#1 in the BZ. I don't see that as relevant to this bug report. That comment is about the question of how GCC can know whether libc's printf supports this feature at all (since in principle the warnings are meant to relate to the features libc actually supports, unless you make a particular format language explicit by specifying gnu_printf rather than printf in the format attribute - though in practice it's only for MinGW that GCC actually knows about a different set of formats supported by default). That comment suggests a possible answer (testing predefined macros after the implicit preinclusion of any implicitly preincluded header; note that the macro in question is now __STDC_IEC_60559_DFP__, in TS 18661-2 and C2X) - although, while glibc has supported stdc-predef.h for some time, current libdfp does not provide such a header. This bug report is about an issue that, in the case where GCC is accepting DFP printf formats, the set of such formats accepted is incomplete. A fix for it should be independent of any fix for the other (harder) issue. (If there is a printf implementation that does in fact support the same subset of DFP formats supported by GCC's printf checking, but not the ones that are the subject of this bug report, that would complicate things.) -- Joseph S. Myers joseph@codesourcery.com