From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27293 invoked by alias); 3 Dec 2011 03:29:20 -0000 Received: (qmail 27284 invoked by uid 22791); 3 Dec 2011 03:29:19 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 03 Dec 2011 03:29:05 +0000 From: "pnewell at cs dot cmu.edu" To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/51391] pragma GCC diag ignored then warning of Winline activates -fno-inline Date: Sat, 03 Dec 2011 03:29:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: preprocessor X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: pnewell at cs dot cmu.edu X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-12/txt/msg00218.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51391 --- Comment #9 from pnewell at cs dot cmu.edu 2011-12-03 03:29:03 UTC --- I just tested on my Linux box and I am getting the results you suggest for -O2 and -O3. It is finding issues with -O, -Os, and -O1, but I think that is my problem (barking on the inlined destructor). However, -O0 still gives me the -fno-inline warnings I just got your email about "Because there is code to explicitly turn off the warning for -O0 but not when using the pragma". I've never seen any documentation about the pragma GCC diagnostic warning having different actions than just on the compile line. Is there any more info on this? Please pardon my questioning this, but does that seem right? I would expect same behavior between a compile line -Winline and a pragma in the code stating "#pragma GCC diagnostic warning "-Winline"? Thanks, Paul