From patchwork Mon Aug 29 11:59:26 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Bruel X-Patchwork-Id: 112028 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 0092AB6F8B for ; Mon, 29 Aug 2011 22:00:06 +1000 (EST) Received: (qmail 1117 invoked by alias); 29 Aug 2011 12:00:02 -0000 Received: (qmail 988 invoked by uid 22791); 29 Aug 2011 12:00:01 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from eu1sys200aog106.obsmtp.com (HELO eu1sys200aog106.obsmtp.com) (207.126.144.121) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 29 Aug 2011 11:59:46 +0000 Received: from beta.dmz-eu.st.com ([164.129.1.35]) (using TLSv1) by eu1sys200aob106.postini.com ([207.126.147.11]) with SMTP ID DSNKTlt/LotXuV4y0A+BnMNJV35NmXcybkJf@postini.com; Mon, 29 Aug 2011 11:59:45 UTC Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id E5FE3FE; Mon, 29 Aug 2011 11:59:27 +0000 (GMT) Received: from Webmail-eu.st.com (safex1hubcas4.st.com [10.75.90.69]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 8630E1C5E; Mon, 29 Aug 2011 11:59:27 +0000 (GMT) Received: from [164.129.122.89] (164.129.122.89) by webmail-eu.st.com (10.75.90.13) with Microsoft SMTP Server (TLS) id 8.2.234.1; Mon, 29 Aug 2011 13:59:26 +0200 Message-ID: <4E5B7F1E.9020808@st.com> Date: Mon, 29 Aug 2011 13:59:26 +0200 From: Christian Bruel User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.2.18) Gecko/20110616 Thunderbird/3.1.11 ThunderBrowse/3.8 MIME-Version: 1.0 To: Jan Hubicka Cc: GCC Patches Subject: Re: PING: [PATCH]: Fix -fbranch-probabilities References: <4E5775C8.3050407@st.com> <20110827000451.GB21785@atrey.karlin.mff.cuni.cz> In-Reply-To: <20110827000451.GB21785@atrey.karlin.mff.cuni.cz> X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On 08/27/2011 02:04 AM, Jan Hubicka wrote: >> Hello, >> >> Could I have a review for the trivial patch posted in >> http://gcc.gnu.org/ml/gcc-patches/2011-08/msg01123.html >> >> -fprofile-use sets flag_branch_probabilities. >> >> But we should also be able to use -fbranch-probabilities on its own >> using the information generated by -fprofile-arcs, as documented. > > OK, thanks! I was under impression that some of gcov tests still use > -fprofile-arcs -fbranch-probabilities pair. yes, indeed, this is was the documentation claims: http://gcc.gnu.org/onlinedocs/gccint/C-Tests.html#C-Tests. e.g for : gcc.misc-tests ... bprob*.c Test -fbranch-probabilities using gcc.misc-tests/bprob.exp, ... but bprob.exp sets feedback_options to "-fprofile-use" > It don't seem to be the > case, so if you add a testcase, you get extra score ;) I feel more like fixing the bprob.exp discrepancy to have the correct pairing with the following. This will act as the testcase, since those tests fail without the patch. OK ? foreach src [lsort [glob -nocomplain $srcdir/$subdir/bprob-*.c]] { --------- 2011-08-29 Christian Bruel * gcc.misc-tests/bprob.exp (feedback_options): Set -fbranch-probabilities. --------- Thanks Christian > > Honza >> >> Many thanks >> >> Christian Index: gcc.misc-tests/bprob.exp =================================================================== --- gcc.misc-tests/bprob.exp (revision 178096) +++ gcc.misc-tests/bprob.exp (working copy) @@ -48,7 +48,7 @@ load_lib profopt.exp set profile_options "-fprofile-arcs" -set feedback_options "-fprofile-use" +set feedback_options "-fbranch-probabilities" foreach profile_option $profile_options feedback_option $feedback_options {