From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1160 invoked by alias); 8 Jan 2008 15:51:23 -0000 Received: (qmail 1147 invoked by uid 22791); 8 Jan 2008 15:51:23 -0000 X-Spam-Check-By: sourceware.org Received: from mail.artimi.com (HELO mail.artimi.com) (194.72.81.2) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 08 Jan 2008 15:51:06 +0000 Received: from rainbow ([192.168.8.46]) by mail.artimi.com with Microsoft SMTPSVC(6.0.3790.3959); Tue, 8 Jan 2008 15:51:03 +0000 From: "Dave Korn" To: "'Dave Korn'" , "'Mark Mendell'" , "'Mark Mitchell'" Cc: , "'gcc'" , "'Hans-Peter Nilsson'" , "'Richard Guenther'" , , References: <20071218000552.GV3656@playstation.sony.com> <20071221220630.Y67443@dair.pair.com> <4772A350.6030907@codesourcery.com> <20080103233308.GD5853@playstation.sony.com> <477F190B.2000807@codesourcery.com> <84fc9c000801050240l6918b59dpd519dea81ddd3ad@mail.gmail.com> <47812F74.3020905@codesourcery.com> <003601c8520c$278d8390$2e08a8c0@CAM.ARTIMI.COM> Subject: RE: __builtin_expect for indirect function calls Date: Tue, 08 Jan 2008 15:51:00 -0000 Message-ID: <003b01c8520e$45b7c3b0$2e08a8c0@CAM.ARTIMI.COM> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <003601c8520c$278d8390$2e08a8c0@CAM.ARTIMI.COM> Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2008-01/txt/msg00063.txt.bz2 On 08 January 2008 15:36, Dave Korn wrote: > On 07 January 2008 21:15, Mark Mendell wrote: > >> A question was raised: Are side effects in the second parameter guaranteed >> to be executed? Is it valid for a compiler to ignore any side effects? > > That perked up my curiosity: > > " The value of C must be a compile-time constant. " > > Can a compile-time constant have run-time side-effects? I couldn't think > up an example off the top of my head... Ah, I thought of one, nevermind, sorry for the noise... cheers, DaveK -- Can't think of a witty .sigline today....