From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1352 invoked by alias); 18 Oct 2004 00:29:30 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 1343 invoked from network); 18 Oct 2004 00:29:29 -0000 Received: from unknown (HELO smtp3.fuse.net) (216.68.8.176) by sourceware.org with SMTP; 18 Oct 2004 00:29:29 -0000 Received: from gx4.fuse.net ([66.42.135.201]) by smtp3.fuse.net (InterMail vM.6.01.03.04 201-2131-111-106-20040729) with ESMTP id <20041018002925.OJJZ22310.smtp3.fuse.net@gx4.fuse.net> for ; Sun, 17 Oct 2004 20:29:25 -0400 Received: from dellpi.pinski.fam ([66.42.135.201]) by gx4.fuse.net (InterMail vG.1.00.00.00 201-2136-104-20040331) with ESMTP id <20041018002926.UDDC3628.gx4.fuse.net@dellpi.pinski.fam>; Sun, 17 Oct 2004 20:29:26 -0400 Received: from [10.0.0.80] (zhivago.i.pinski.fam [10.0.0.80]) by dellpi.pinski.fam (8.12.2/8.12.1) with ESMTP id i9I0TMVT027711; Sun, 17 Oct 2004 20:29:23 -0400 (EDT) In-Reply-To: <877jposwsz.fsf@codesourcery.com> References: <200410172348.i9HNmoX04480@bemr-lnx-002.cisco.com> <877jposwsz.fsf@codesourcery.com> Mime-Version: 1.0 (Apple Message framework v618) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: Content-Transfer-Encoding: 7bit Cc: gcc@gcc.gnu.org, Eliot Dresselhaus From: Andrew Pinski Subject: Re: bug w/ inline of inline? Date: Mon, 18 Oct 2004 07:40:00 -0000 To: Zack Weinberg X-SW-Source: 2004-10/txt/msg00682.txt.bz2 On Oct 17, 2004, at 8:18 PM, Zack Weinberg wrote: > Eliot Dresselhaus writes: > >> In this example >> >> static inline int f (int x) { return x + 1; } >> >> static inline int g (int x, inline int f (int x)) >> { return 1 + f (x); } >> >> int h (int x) >> { return g (x, f); } >> >> is h supposed to optimize to return x + 2 or supposed to actually call >> f. > > GCC is allowed to do either. It would be good if it produced > "return x + 2;" Please file a missed-optimization bug report. We have one already, PR 9079: . Thanks, Andrew Pinski a gcc bug master