From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753355AbdFSC7A (ORCPT ); Sun, 18 Jun 2017 22:59:00 -0400 Received: from mga06.intel.com ([134.134.136.31]:47494 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753227AbdFSC67 (ORCPT ); Sun, 18 Jun 2017 22:58:59 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,359,1493708400"; d="scan'208";a="115970722" Subject: Re: [PATCH v1 1/2] perf report: Check for fused instruction pair To: Arnaldo Carvalho de Melo Cc: jolsa@kernel.org, peterz@infradead.org, mingo@redhat.com, alexander.shishkin@linux.intel.com, Linux-kernel@vger.kernel.org, ak@linux.intel.com, kan.liang@intel.com, yao.jin@intel.com References: <1497408821-3211-1-git-send-email-yao.jin@linux.intel.com> <1497408821-3211-2-git-send-email-yao.jin@linux.intel.com> <20170616162152.GI3645@kernel.org> From: "Jin, Yao" Message-ID: <9cc30de7-826d-1bfc-944d-aa9eb9b6803b@linux.intel.com> Date: Mon, 19 Jun 2017 10:58:55 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <20170616162152.GI3645@kernel.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/17/2017 12:21 AM, Arnaldo Carvalho de Melo wrote: > Em Wed, Jun 14, 2017 at 10:53:40AM +0800, Jin Yao escreveu: >> Macro fusion merges two instructions to a single micro-op. Intel >> core platform performs this hardware optimization under limited >> circumstances. For example, CMP + JCC can be "fused" and executed >> /retired together. While with sampling this can result in the >> sample sometimes being on the JCC and sometimes on the CMP. >> So for the fused instruction pair, they could be considered >> together. > doing it as a weak function that will be overriden by the host arch > doesn't work, as we also support cross-annotation. So you have to take > into account perf_evsel__env_arch(evsel), etc. > > Please search for perf_evsel__env_arch(evsel) in the annotation source > files to see how it is used. > > - Arnaldo > Hi Arnaldo, Thanks so much for pointing out that the weak function doesn't work. I have changed it to arch-specific function and just send out v2 series for reviewing. Thanks Jin Yao