From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by sourceware.org (Postfix) with ESMTPS id 788D93858D28 for ; Thu, 4 May 2023 08:30:23 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 788D93858D28 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=suse.cz Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 8CCA420981; Thu, 4 May 2023 08:30:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1683189022; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=KRcjRrr1Fq1GVmC2CJDffzfDxYswVY6Ue5pPytx3jKw=; b=0jygRgV6gJyc2IM1l2HmAjVbwUklGaTOqB64iajhM7iHigxNiSIx/atqWma7b6vtgVxcYB waeiqbCe3qt//J9yx8uc71NC0RZLOkoVtsA/7NQxgA/yn/ucrtyYmqPqmXzqFJWWxOYt0g 6cOrk3G7Lc56W3xBWx4mgqLnEwM7BQM= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1683189022; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=KRcjRrr1Fq1GVmC2CJDffzfDxYswVY6Ue5pPytx3jKw=; b=CFPFPV3dTsiTjRfgK6kzYNwHXCHHuNZXMk66tM+Cq0SgcBLVTE2P72vCOX3glJgrAW5S21 2Rd+Ht3CM/YeyxDQ== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 732CE13444; Thu, 4 May 2023 08:30:22 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id F6IhGx5tU2TGNwAAMHmgww (envelope-from ); Thu, 04 May 2023 08:30:22 +0000 Message-ID: Date: Thu, 4 May 2023 10:30:22 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.1 Subject: Re: Question on patch -fprofile-partial-training Content-Language: en-US To: Qing Zhao , Jan Hubicka Cc: gcc Patches References: <2A707DB2-5BCE-4F1F-A971-67AC55B30297@oracle.com> From: =?UTF-8?Q?Martin_Li=c5=a1ka?= In-Reply-To: <2A707DB2-5BCE-4F1F-A971-67AC55B30297@oracle.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_NONE,SPF_SOFTFAIL,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 5/3/23 21:10, Qing Zhao via Gcc-patches wrote: > Hi, Jan, > > You added the following patch into gcc10: > > From 34fbe3f0946f88828765184ed6581bda62cdf49f Mon Sep 17 00:00:00 2001 > From: Jan Hubicka > Date: Thu, 5 Dec 2019 19:12:51 +0100 > Subject: [PATCH] cgraphclones.c (localize_profile): New function. > > * cgraphclones.c (localize_profile): New function. > (cgraph_node::create_clone): Use it for partial profiles. > * common.opt (fprofile-partial-training): New flag. > * doc/invoke.texi (-fprofile-partial-training): Document. > * ipa-cp.c (update_profiling_info): For partial profiles do not > set function profile to zero. > * profile.c (compute_branch_probabilities): With partial profile > watch if edge count is zero and turn all probabilities to guessed. > (compute_branch_probabilities): For partial profiles do not apply > profile when entry count is zero. > * tree-profile.c (tree_profiling): Only do value_profile_transformations > when profile is read. > > My question is: Hello. Why would anybody backport such change to unsupported code-stream of GCC 8? Generally speaking, I discourage from doing that. Martin > > Can this patch be back ported to GCC8 easily? I am wondering any significant > Change between GCC8 and GCC10 that might make the backporting very hard> > Thanks a lot for your help. > > Qing