Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1221050imm; Wed, 25 Jul 2018 13:52:30 -0700 (PDT) X-Google-Smtp-Source: AAOMgpebB41W/7O1wYk/gEgtL1Mp1vU9X1Z0j7iBPjr++lbK2TemmZRkCOZngQOd04P9KWXoMCvn X-Received: by 2002:a63:4d5:: with SMTP id 204-v6mr21960094pge.129.1532551950285; Wed, 25 Jul 2018 13:52:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532551950; cv=none; d=google.com; s=arc-20160816; b=v9Z+SKQReTHqT4g81zoakViBbeP/VVXxaHE6PljrMlkYQIzbNl9jBTylGG2SELaLSc UCIxOht8ODWrc9GrAiy7p0G+DOFvcYrS2Cxc7eNLsXanCAE1qIVwzyKqh8Ok7U6y5Thi 1+wO7BQ1csBPFof/qSL7zykuiz2rqgm9aTGk2ACQN72TqQa3/53u1s04954fSLkWoflh KWo/2PCdsNp8JpZdg9Dw22W870khVS+pm7JiIU4prOdkeOdnkLFgHuBLgBEs8tq5jfgp g2gWpQQHWvHycZyVCkYwgvMQS0AB0UIC3F2E0Xm8paJ59T2N6eZWOR9cSLYIb8LS4TSa DNqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date:arc-authentication-results; bh=nDwJdA53mD170SdrHqSoAsFqTXD0fi2c+Tvu9q4LZn4=; b=mF3pDLcS/CbbSo8uVTIhrGV3/p59YdkkXAKiiUmisFVsK6vLADSo4Zk6k6CyGtutRe VCSX8as7TjMnjBe9fWYFp8CLUOogyI082MiEN5QG/PQwhlEdP/zRHzuX13DEFhuv5wKh qdw6+KinY6hfgFiJ6tf7sF4vBrpS4Jd4ESfRt6YkTTLveADHBJw1BqB03NUpT4iCgUmy BBVMj+7m4JUq7g5y4/TOAAyCa50j2YxZHsO/+KnQ4GoFqzDeP3f5UJ2yajVUc6UuZvXk 6iGqG/5IfIss1KqbF1ky1JRloToSZ+Rl2l+W903CcuIOpCluPlmCB6WtLwlUHrRQ5f9F myfw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t18-v6si12823015plo.163.2018.07.25.13.52.15; Wed, 25 Jul 2018 13:52:30 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731420AbeGYWDr (ORCPT + 99 others); Wed, 25 Jul 2018 18:03:47 -0400 Received: from terminus.zytor.com ([198.137.202.136]:37773 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730606AbeGYWDr (ORCPT ); Wed, 25 Jul 2018 18:03:47 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id w6PKnxId501223 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 25 Jul 2018 13:49:59 -0700 Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id w6PKnxTN501220; Wed, 25 Jul 2018 13:49:59 -0700 Date: Wed, 25 Jul 2018 13:49:59 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Jiri Olsa Message-ID: Cc: mingo@kernel.org, alexander.shishkin@linux.intel.com, peterz@infradead.org, hpa@zytor.com, eranian@google.com, jolsa@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, dsahern@gmail.com, acme@redhat.com, namhyung@kernel.org, davidcc@google.com Reply-To: mingo@kernel.org, alexander.shishkin@linux.intel.com, peterz@infradead.org, eranian@google.com, hpa@zytor.com, jolsa@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, dsahern@gmail.com, acme@redhat.com, namhyung@kernel.org, davidcc@google.com In-Reply-To: <20180712135202.14774-1-jolsa@kernel.org> References: <20180712135202.14774-1-jolsa@kernel.org> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf tools: Synthesize GROUP_DESC feature in pipe mode Git-Commit-ID: e8fedff1cc729fd227924305152ccc6f580e8c83 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-0.7 required=5.0 tests=ALL_TRUSTED,BAYES_00, DATE_IN_FUTURE_48_96 autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: e8fedff1cc729fd227924305152ccc6f580e8c83 Gitweb: https://git.kernel.org/tip/e8fedff1cc729fd227924305152ccc6f580e8c83 Author: Jiri Olsa AuthorDate: Thu, 12 Jul 2018 15:52:02 +0200 Committer: Arnaldo Carvalho de Melo CommitDate: Tue, 24 Jul 2018 14:53:20 -0300 perf tools: Synthesize GROUP_DESC feature in pipe mode Stephan reported, that pipe mode does not carry the group information and thus the piped report won't display the grouped output for following command: # perf record -e '{cycles,instructions,branches}' -a sleep 4 | perf report It has no idea about the group setup, so it will display events separately: # Overhead Command Shared Object ... # ........ ............... ....................... # 6.71% swapper [kernel.kallsyms] 2.28% offlineimap libpython2.7.so.1.0 0.78% perf [kernel.kallsyms] ... Fix GROUP_DESC feature record to be synthesized in pipe mode, so the report output is grouped if there are groups defined in record: # Overhead Command Shared ... # ........................ ............... ....... # 7.57% 0.16% 0.30% swapper [kernel 1.87% 3.15% 2.46% offlineimap libpyth 1.33% 0.00% 0.00% perf [kernel ... Reported-by: Stephane Eranian Signed-off-by: Jiri Olsa Tested-by: Arnaldo Carvalho de Melo Tested-by: Stephane Eranian Cc: Alexander Shishkin Cc: David Ahern Cc: David Carrillo-Cisneros Cc: Namhyung Kim Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/20180712135202.14774-1-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/header.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c index 653ff65aa2c3..5af58aac91ad 100644 --- a/tools/perf/util/header.c +++ b/tools/perf/util/header.c @@ -2587,7 +2587,7 @@ static const struct feature_ops feat_ops[HEADER_LAST_FEATURE] = { FEAT_OPR(NUMA_TOPOLOGY, numa_topology, true), FEAT_OPN(BRANCH_STACK, branch_stack, false), FEAT_OPR(PMU_MAPPINGS, pmu_mappings, false), - FEAT_OPN(GROUP_DESC, group_desc, false), + FEAT_OPR(GROUP_DESC, group_desc, false), FEAT_OPN(AUXTRACE, auxtrace, false), FEAT_OPN(STAT, stat, false), FEAT_OPN(CACHE, cache, true),