Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2712150pxa; Fri, 7 Aug 2020 19:43:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyeIheq/CYhj9L4FeXJsmbxQzgje8KFLa9YxCClJy4BhitzJTZgmTFg7ISKgVKy67sIrfU2 X-Received: by 2002:a17:907:41dc:: with SMTP id og20mr12645797ejb.183.1596854601781; Fri, 07 Aug 2020 19:43:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596854601; cv=none; d=google.com; s=arc-20160816; b=Ff+aGdfUUoccOvNGKI3uMlne2ip9yRpkVk/cBjc4m1+Y3ChNtROMoz3cAQrCvLqLhp F4bYyKU7P8vLjEFF05ijVyb6MWtD5u6v9ix4iTVfZyLEVMWDkboe9nQdUgI7lQo1X86o CP/qEXNDiGIsDejCFyEuA0UILn3/FFOTGKoKuzsJoI4SwyGhxCpq2zgF93iRTXHvhi/G T4VrvX91OgIS8GvNJskVA+QCcE2M+A0uhnymoMqxOYC9IV5ugnRavvByaJQ8NVUG9Ox0 h0THzagHZd/lzWo1pwEF4q3GfPvFRLRwqyjN9q2nPsVWiC+WIy77IfVtj8+qwX1++PGW K9ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=kW4G0zGaMrzoXRdoWpPfrvRSRKYz4wc1F/qThm1mflM=; b=oVhdmIsCfGsdRBAVS7GRiCSqNaJ1QcOphw/QtqGn1c9HrgRCIuiK79zfUfEXU5V4Dd fl4mfFVq+ni6BfgiytdPYJiopLc/0P3v20p7voqFljKKsJl9KgfIY5XWs+U3YV/ItxbY AljCZy6NwAC2waNp03AFJhd0RFQHOIjCc9qDLik/Wc65Sh+4AiIXMEgaU4KJiNvzx4jW f59Y7WHNn3LI8bKLGNc0V6guaorNiLyQCKRR0Ve6Zd+MX9XzVydT+XmRStI1/NfTgTF0 OjEDM6uAxaYGhhdX2ieFhJXNJsW7e8ZEGRZ/IpnIFlfoC3CKsZDUGYiIhWm+ePuEUeAC 0q7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iwy0z6or; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v26si6661133ejx.750.2020.08.07.19.42.59; Fri, 07 Aug 2020 19:43:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iwy0z6or; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726240AbgHHCjz (ORCPT + 99 others); Fri, 7 Aug 2020 22:39:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44498 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726200AbgHHCjx (ORCPT ); Fri, 7 Aug 2020 22:39:53 -0400 Received: from mail-qk1-x743.google.com (mail-qk1-x743.google.com [IPv6:2607:f8b0:4864:20::743]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8055AC061756 for ; Fri, 7 Aug 2020 19:39:53 -0700 (PDT) Received: by mail-qk1-x743.google.com with SMTP id b79so3499756qkg.9 for ; Fri, 07 Aug 2020 19:39:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=kW4G0zGaMrzoXRdoWpPfrvRSRKYz4wc1F/qThm1mflM=; b=iwy0z6orqAwmkflEtMsZRO521q9Q+ADX2T46VZ1FUO394n5whOvK+psDbcTSH4nPuw nWJbv/cJo8Eyz8W+g/v42h63HdIQuQbwDnbJR/fYypZbhualndH5tdCGBvB2cNlxR/uT b4ckdNzSU1zIZAbnyzx+zH7yJ3nOwTtuKmHZd0uSX6MhB+GEwn8xLdMWDpcEjHO9Ssga o/nUvCqLypxR+Ioh6DILL9g4HIj20Fd9u+sQAKqU7xUhiLRzLPZBzXePS1cvbRgcITWC uTL5qKFBmwC/wvqkOT2gzP6kA7HIJgaZ4S29n3T7O8zt4jWaTdCMJJhrY9IJlDRyXouT 0cgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=kW4G0zGaMrzoXRdoWpPfrvRSRKYz4wc1F/qThm1mflM=; b=TSg2A/B/y4EqRQ5rxegmadCZakWkvCNlf9Jq/6YnmPdsvQo9G5pcqopTdOJunYmtJY 5Yh9hBOAy4ekdnP5qSU1NGsBNV3qIQrQnfPGgtynHXGgKP5C8oSj5g9xlUilkFqWKHMh uQ6bnD79WwaELohCFcRKKWhT03YvAXDdrVeVcvzA2NkmsDJ4SW3nUv/gXIEP3REx4ejt m1AFnKprn/Sw05WbdgkvpOfj4NZ5CXO4jYvOGSu+6zdZrfbwgzhvt/ectTHYRqqKvAo1 u1DaRVKDq+ZN72oTvmUO0luZsg9Q/VQHdQafJVg7YZNgc7ukqgMb6gKVEijxv8/f6PaT k5JQ== X-Gm-Message-State: AOAM531yX24koPm/A5ccKh0E6M6pe4wwEwjNsJWW0j4vglV0VXZD29AE yjRm+Mw1hEVFt8XDVSDS4DE= X-Received: by 2002:a37:9c58:: with SMTP id f85mr15492512qke.345.1596854392791; Fri, 07 Aug 2020 19:39:52 -0700 (PDT) Received: from vultr.guest ([66.42.85.36]) by smtp.gmail.com with ESMTPSA id n33sm7818702qtd.43.2020.08.07.19.39.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 07 Aug 2020 19:39:52 -0700 (PDT) From: Changbin Du To: Jiri Olsa , Arnaldo Carvalho de Melo Cc: Peter Zijlstra , Ingo Molnar , Namhyung Kim , Steven Rostedt , linux-kernel@vger.kernel.org, Changbin Du Subject: [PATCH v8 14/18] perf: ftrace: allow set graph depth by '--graph-opts' Date: Sat, 8 Aug 2020 10:31:37 +0800 Message-Id: <20200808023141.14227-15-changbin.du@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200808023141.14227-1-changbin.du@gmail.com> References: <20200808023141.14227-1-changbin.du@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is to have a consistent view of all graph tracer options. The original option '--graph-depth' is marked as deprecated. Signed-off-by: Changbin Du --- tools/perf/Documentation/perf-ftrace.txt | 5 +---- tools/perf/builtin-ftrace.c | 5 ++--- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/tools/perf/Documentation/perf-ftrace.txt b/tools/perf/Documentation/perf-ftrace.txt index 6fa927e5971b..08216634d2bc 100644 --- a/tools/perf/Documentation/perf-ftrace.txt +++ b/tools/perf/Documentation/perf-ftrace.txt @@ -98,16 +98,13 @@ OPTIONS specify multiple functions. It will be passed to 'set_graph_notrace' in tracefs. --D:: ---graph-depth=:: - Set max depth for function graph tracer to follow - --graph-opts:: List of options allowed to set: nosleep-time - Measure on-CPU time only for function_graph tracer. noirqs - Ignore functions that happen inside interrupt. verbose - Show process names, PIDs, timestamps, etc. thresh= - Setup trace duration threshold in microseconds. + depth= - Set max depth for function graph tracer to follow. SEE ALSO -------- diff --git a/tools/perf/builtin-ftrace.c b/tools/perf/builtin-ftrace.c index ca61f8b8bbf6..bc3b35d18167 100644 --- a/tools/perf/builtin-ftrace.c +++ b/tools/perf/builtin-ftrace.c @@ -751,6 +751,7 @@ static int parse_graph_tracer_opts(const struct option *opt, { .name = "noirqs", .value_ptr = &ftrace->graph_noirqs }, { .name = "verbose", .value_ptr = &ftrace->graph_verbose }, { .name = "thresh", .value_ptr = &ftrace->graph_thresh }, + { .name = "depth", .value_ptr = &ftrace->graph_depth }, { .name = NULL, } }; @@ -819,10 +820,8 @@ int cmd_ftrace(int argc, const char **argv) parse_filter_func), OPT_CALLBACK('g', "nograph-funcs", &ftrace.nograph_funcs, "func", "Set nograph filter on given functions", parse_filter_func), - OPT_INTEGER('D', "graph-depth", &ftrace.graph_depth, - "Max depth for function graph tracer"), OPT_CALLBACK(0, "graph-opts", &ftrace, "options", - "graph tracer options, available options: nosleep-time,noirqs,verbose,thresh=", + "graph tracer options, available options: nosleep-time,noirqs,verbose,thresh=,depth=", parse_graph_tracer_opts), OPT_CALLBACK('m', "buffer-size", &ftrace.percpu_buffer_size, "size", "size of per cpu buffer", parse_buffer_size), -- 2.25.1