From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754581AbbKCIV6 (ORCPT ); Tue, 3 Nov 2015 03:21:58 -0500 Received: from mx1.redhat.com ([209.132.183.28]:47151 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750716AbbKCIV5 (ORCPT ); Tue, 3 Nov 2015 03:21:57 -0500 Date: Tue, 3 Nov 2015 09:21:52 +0100 From: Jiri Olsa To: Namhyung Kim Cc: Arnaldo Carvalho de Melo , Ingo Molnar , Peter Zijlstra , LKML , Brendan Gregg , David Ahern , Frederic Weisbecker , Andi Kleen , Kan Liang Subject: Re: [PATCH v3 1/4] perf report: Support folded callchain mode on --stdio Message-ID: <20151103082152.GG23878@krava.brq.redhat.com> References: <1446535111-31713-1-git-send-email-namhyung@kernel.org> <1446535111-31713-2-git-send-email-namhyung@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1446535111-31713-2-git-send-email-namhyung@kernel.org> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 03, 2015 at 04:18:28PM +0900, Namhyung Kim wrote: > Add new call chain option (-g) 'folded' to print callchains in a line. > The callchains are separated by semicolons, and preceded by (absolute) > percent values and a space. > > For example, following 20 lines can be printed in 3 lines with the > folded output mode; > > $ perf report -g flat --no-children | grep -v ^# | head -20 > 60.48% swapper [kernel.vmlinux] [k] intel_idle > 54.60% > intel_idle > cpuidle_enter_state > cpuidle_enter > call_cpuidle > cpu_startup_entry > start_secondary > > 5.88% > intel_idle > cpuidle_enter_state > cpuidle_enter > call_cpuidle > cpu_startup_entry > rest_init > start_kernel > x86_64_start_reservations > x86_64_start_kernel > > $ perf report -g folded --no-children | grep -v ^# | head -3 > 60.48% swapper [kernel.vmlinux] [k] intel_idle > 54.60% intel_idle;cpuidle_enter_state;cpuidle_enter;call_cpuidle;cpu_startup_entry;start_secondary > 5.88% intel_idle;cpuidle_enter_state;cpuidle_enter;call_cpuidle;cpu_startup_entry;rest_init;start_kernel;x86_64_start_reservations;x86_64_start_kernel > > This mode is supported only for --stdio now and intended to be used by > some scripts like in FlameGraphs[1]. Support for other UI might be > added later. > > [1] http://www.brendangregg.com/FlameGraphs/cpuflamegraphs.html > > Requested-by: Brendan Gregg > Signed-off-by: Namhyung Kim > --- > tools/perf/ui/stdio/hist.c | 54 +++++++++++++++++++++++++++++++++++++++++++++ > tools/perf/util/callchain.c | 6 +++++ > tools/perf/util/callchain.h | 3 ++- > 3 files changed, 62 insertions(+), 1 deletion(-) missing doc update, otherwise Acked-by: Jiri Olsa thanks, jirka