From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751933AbdF3OCH convert rfc822-to-8bit (ORCPT ); Fri, 30 Jun 2017 10:02:07 -0400 Received: from mga07.intel.com ([134.134.136.100]:5445 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751563AbdF3OCG (ORCPT ); Fri, 30 Jun 2017 10:02:06 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,286,1496127600"; d="scan'208";a="105662708" From: "Liang, Kan" To: Jiri Olsa CC: "acme@kernel.org" , "linux-kernel@vger.kernel.org" , "mingo@redhat.com" , "peterz@infradead.org" , "Hunter, Adrian" , "alexander.shishkin@linux.intel.com" , "ak@linux.intel.com" Subject: RE: [PATCH] perf tools: set no branch type for dummy event in PT Thread-Topic: [PATCH] perf tools: set no branch type for dummy event in PT Thread-Index: AQHS8Bt1uVwRKpcWuUaNyttmillp0qI7cpcAgACGV+D//3yMAIAAiC4QgAB6yQCAAPnzAA== Date: Fri, 30 Jun 2017 14:01:56 +0000 Message-ID: <37D7C6CF3E00A74B8858931C1DB2F07753714794@SHSMSX103.ccr.corp.intel.com> References: <20170628143153.29643-1-kan.liang@intel.com> <20170629152912.GB1463@krava> <37D7C6CF3E00A74B8858931C1DB2F0775371415B@SHSMSX103.ccr.corp.intel.com> <20170629153932.GA2924@krava> <37D7C6CF3E00A74B8858931C1DB2F077537141A7@SHSMSX103.ccr.corp.intel.com> <20170630070624.GD6815@krava> In-Reply-To: <20170630070624.GD6815@krava> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiOWNhNjhjMTQtMmQ5MC00YWRiLTlhYzYtMjAzZjI2MTU2ZWQ2IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE2LjUuOS4zIiwiVHJ1c3RlZExhYmVsSGFzaCI6Imwxb29QYVwvWXlBNTRLNForSmxieWIyd3BtOEFvMG5hMzZSbnBHeGRjaXlJPSJ9 x-ctpclassification: CTP_IC dlp-product: dlpe-windows dlp-version: 10.0.102.7 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Thu, Jun 29, 2017 at 03:50:29PM +0000, Liang, Kan wrote: > > > > > > > > > > On Thu, Jun 29, 2017 at 03:31:45PM +0000, Liang, Kan wrote: > > > > > > SNIP > > > > > > > > > static int intel_pt_recording_options(struct auxtrace_record *itr, > > > > > > struct perf_evlist *evlist, > > > > > > struct record_opts *opts) @@ - > 701,6 > > > +717,8 @@ static > > > > > > int intel_pt_recording_options(struct > > > > > auxtrace_record *itr, > > > > > > > perf_evsel__set_sample_bit(switch_evsel, > > > > > TIME); > > > > > > > perf_evsel__set_sample_bit(switch_evsel, > > > > > CPU); > > > > > > > > > > > > + > add_no_lbr_config_term(&switch_evsel- > > > > > >config_terms); > > > > > > + > > > > > > > > > > hum, why can't you change the sample bit directly? with: > > > > > > > > > > perf_evsel__reset_sample_bit(switch_evsel, > > > > > BRANCH_STACK); > > > > > > > > It will be overwrite in perf_evsel__config. > > > > > > > > > > where? you set the evsel->no_aux_samples > > > > Yes for switch_evsel, but no for tracking_evsel. > > > > If it's only for switch_evsel, yes, we can change the sample bit directly. > > But I think we should use the same method for both of them. > > > we could set the no_aux_samples for the tracking_evsel as well > Yes, I will do it in next version. Thanks, Kan