From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753374AbdBUOEY (ORCPT ); Tue, 21 Feb 2017 09:04:24 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:52386 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753139AbdBUOEP (ORCPT ); Tue, 21 Feb 2017 09:04:15 -0500 Subject: Re: [PATCH v6 2/3] perf tool: add PERF_RECORD_NAMESPACES to include namespaces related info To: Jiri Olsa References: <148654265580.27983.8822211570127163843.stgit@hbathini.in.ibm.com> <148654270963.27983.11333098688761605858.stgit@hbathini.in.ibm.com> <20170208125732.GC22166@krava> Cc: ast@fb.com, peterz@infradead.org, lkml , acme@kernel.org, alexander.shishkin@linux.intel.com, mingo@redhat.com, daniel@iogearbox.net, rostedt@goodmis.org, Ananth N Mavinakayanahalli , ebiederm@xmission.com, sargun@sargun.me, Aravinda Prasad , brendan.d.gregg@gmail.com From: Hari Bathini Date: Tue, 21 Feb 2017 19:33:58 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <20170208125732.GC22166@krava> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable x-cbid: 17022114-0012-0000-0000-000003BBC900 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17022114-0013-0000-0000-00001B3D0CC7 Message-Id: X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-02-21_11:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1612050000 definitions=main-1702210136 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jiri, On Wednesday 08 February 2017 06:27 PM, Jiri Olsa wrote: > On Wed, Feb 08, 2017 at 02:01:49PM +0530, Hari Bathini wrote: >> This patch updates perf tool to examine PERF_RECORD_NAMESPACES events >> emitted by the kernel when fork, clone, setns or unshare are invoked. >> Also, it synthesizes PERF_RECORD_NAMESPACES events for processes that >> were running prior to invocation of perf record, the data for which >> is taken from /proc/$PID/ns. These changes make way for analyzing >> events with regard to namespaces. >> >> Signed-off-by: Hari Bathini >> --- >> tools/include/uapi/linux/perf_event.h | 38 +++++++++ >> tools/perf/builtin-annotate.c | 1 >> tools/perf/builtin-diff.c | 1 >> tools/perf/builtin-inject.c | 14 +++ >> tools/perf/builtin-kmem.c | 1 >> tools/perf/builtin-kvm.c | 2 >> tools/perf/builtin-lock.c | 1 >> tools/perf/builtin-mem.c | 1 >> tools/perf/builtin-record.c | 33 +++++++- >> tools/perf/builtin-report.c | 1 >> tools/perf/builtin-sched.c | 1 >> tools/perf/builtin-script.c | 41 +++++++++ >> tools/perf/builtin-trace.c | 3 - >> tools/perf/perf.h | 1 >> tools/perf/util/Build | 1 >> tools/perf/util/data-convert-bt.c | 2 >> tools/perf/util/event.c | 143 ++++++++++++++++++++++++++++++++- >> tools/perf/util/event.h | 19 ++++ >> tools/perf/util/evsel.c | 3 + >> tools/perf/util/machine.c | 34 ++++++++ >> tools/perf/util/machine.h | 3 + >> tools/perf/util/namespaces.c | 35 ++++++++ >> tools/perf/util/namespaces.h | 26 ++++++ >> tools/perf/util/session.c | 7 ++ >> tools/perf/util/thread.c | 44 ++++++++++ >> tools/perf/util/thread.h | 6 + >> tools/perf/util/tool.h | 2 >> 27 files changed, 450 insertions(+), 14 deletions(-) >> create mode 100644 tools/perf/util/namespaces.c >> create mode 100644 tools/perf/util/namespaces.h > could you please split this patch into logically separated changes, like: > - adding PERF_RECORD_NAMESPACES event with perf_event__process_namespaces > machinery > - synthesize support (perf_event__synthesize_namespaces) for record > - script print support > - perf_event__fprintf print support > > or any other split that'd make sense, it's too many changes for one patch now > > Thanks for the review. Posted v7 with the changes included.. - Hari