From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 554 invoked by alias); 28 Aug 2014 10:52:09 -0000 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 Received: (qmail 525 invoked by uid 48); 28 Aug 2014 10:52:05 -0000 From: "dmitry.petroff at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/62282] Undefined reference with __inline __attribute(__gnu_inline__) with -O0 Date: Thu, 28 Aug 2014 10:52:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 4.8.3 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dmitry.petroff at gmail dot com X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: attachments.created Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-08/txt/msg01892.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62282 --- Comment #3 from Dmitry Petrov --- Created attachment 33408 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=33408&action=edit g++ + gperf bug in action Guys, I'm software developer myself and I can understand your attitute to "declare bug as a feature". But please note, that this bug is breaking normal development with gperf which is also a GNU tool. In the attached archive try make => failure in compiling bug++ make CFLAGS=-O => success, inlining happens make CXX=clang++ => success You're saying "we've designed this extension and it works as it should". But why gcc links this successfully, but g++ don't? It looks like either C or C++ compiler bug. P. S. I'm using gperf to generate code for both C server-side and C++ tools/testcases and such g++ behaviour is really unpleasing when making debug builds.