From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754003AbbESGtg (ORCPT ); Tue, 19 May 2015 02:49:36 -0400 Received: from LGEMRELSE6Q.lge.com ([156.147.1.121]:41970 "EHLO lgemrelse6q.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750862AbbESGte (ORCPT ); Tue, 19 May 2015 02:49:34 -0400 X-Original-SENDERIP: 10.177.220.203 X-Original-MAILFROM: namhyung@kernel.org Date: Tue, 19 May 2015 15:40:07 +0900 From: Namhyung Kim To: Jiri Olsa Cc: Arnaldo Carvalho de Melo , Ingo Molnar , Peter Zijlstra , LKML , David Ahern , Adrian Hunter , Andi Kleen , Frederic Weisbecker , Stephane Eranian Subject: Re: [PATCH 07/40] perf tools: Handle indexed data file properly Message-ID: <20150519064007.GG21663@sejong> References: <1431909055-21442-1-git-send-email-namhyung@kernel.org> <1431909055-21442-8-git-send-email-namhyung@kernel.org> <20150518183728.GA12169@krava> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20150518183728.GA12169@krava> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 18, 2015 at 08:37:28PM +0200, Jiri Olsa wrote: > On Mon, May 18, 2015 at 09:30:22AM +0900, Namhyung Kim wrote: > > When perf detects data file has index table, process header part first > > and then rest data files in a row. Note that the indexed sample data is > > recorded for each cpu/thread separately, it's already ordered with > > respect to themselves so no need to use the ordered event queue > > interface. > > > > Signed-off-by: Namhyung Kim > > --- > > tools/perf/perf.c | 1 + > > tools/perf/perf.h | 2 ++ > > tools/perf/util/session.c | 55 +++++++++++++++++++++++++++++++++++++++-------- > > 3 files changed, 49 insertions(+), 9 deletions(-) > > > > diff --git a/tools/perf/perf.c b/tools/perf/perf.c > > index b857fcbd00cf..960942d9a0b7 100644 > > --- a/tools/perf/perf.c > > +++ b/tools/perf/perf.c > > @@ -27,6 +27,7 @@ const char perf_more_info_string[] = > > int use_browser = -1; > > static int use_pager = -1; > > const char *input_name; > > +bool perf_has_index; > > I probably missed some discussion here, but why is this not > perf_session function? I saw some non session related functions > further in the patchset using this.. is that the reason? > > it seems fairly perf_session specific.. might be worth to > keep it there? just asking ;-) I agree. But it requires to pass a pointer to session wherever processing samples. Arnaldo said that he wanted to remove accesses to a session in general. So I added the global variable. https://lkml.org/lkml/2015/3/3/353 Thanks, Namhyung