lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120308072258.GB20784@elte.hu>
Date:	Thu, 8 Mar 2012 08:22:58 +0100
From:	Ingo Molnar <mingo@...e.hu>
To:	Arun Sharma <asharma@...com>
Cc:	linux-kernel@...r.kernel.org,
	Arnaldo Carvalho de Melo <acme@...hat.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Mike Galbraith <efault@....de>,
	Paul Mackerras <paulus@...ba.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Stephane Eranian <eranian@...gle.com>,
	Namhyung Kim <namhyung.kim@....com>,
	Tom Zanussi <tzanussi@...il.com>,
	linux-perf-users@...r.kernel.org
Subject: Re: [PATCH 2/2] perf: Add a new sort order: SORT_INCLUSIVE


* Arun Sharma <asharma@...com> wrote:

> @@ -71,8 +71,12 @@ static int perf_evsel__add_hist_entry(struct perf_evsel *evsel,
>  	}
>  
>  	cursor = &evsel->hists.callchain_cursor;
> -	he = __hists__add_entry_single(&evsel->hists, al, parent,
> -				       cursor, sample->period);
> +	if (sort__first_dimension == SORT_INCLUSIVE)
> +		he = __hists__add_entry_inclusive(&evsel->hists, al, parent,
> +						  cursor, sample->period);
> +	else
> +		he = __hists__add_entry_single(&evsel->hists, al, parent,
> +					       cursor, sample->period);

If sort__first_dimension is available to hist.c then I think 
there should still be a simple __hists__add_entry() function in 
hist.c, which perf_evsel__add_hist_entry() calls - which then 
calls the static inline __hists__add_entry_inclusive() and 
__hists__add_entry_single() functions within hist.c.

I.e. this refactoring and splitup of the function into two parts 
is not a detail that should matter to builtin-report.c's 
perf_evsel__add_hist_entry().

Thanks,

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ