Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-02-26 Thread Jin, Yao
On 1/23/2018 10:19 PM, Jiri Olsa wrote: On Mon, Jan 22, 2018 at 01:10:31PM +0800, Jin, Yao wrote: On 1/16/2018 9:17 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 09:06:09PM +0800, Jin, Yao wrote: Just tested. But looks it's not OK for '--per-thread' case. yea, I haven't tested much

Re: [PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-23 Thread Jin, Yao
On 2/23/2018 11:29 PM, Arnaldo Carvalho de Melo wrote: Em Fri, Feb 23, 2018 at 09:25:00AM +0100, Peter Zijlstra escreveu: On Fri, Feb 23, 2018 at 10:35:58PM +0800, Jin Yao wrote: Unlike the perf report interactive annotate mode, the perf annotate doesn't display the LBR data. perf record

Re: [PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-23 Thread Jin, Yao
On 2/23/2018 11:29 PM, Arnaldo Carvalho de Melo wrote: Em Fri, Feb 23, 2018 at 09:25:00AM +0100, Peter Zijlstra escreveu: On Fri, Feb 23, 2018 at 10:35:58PM +0800, Jin Yao wrote: Unlike the perf report interactive annotate mode, the perf annotate doesn't display the LBR data. perf record

Re: [PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-23 Thread Jin, Yao
On 2/23/2018 4:25 PM, Peter Zijlstra wrote: On Fri, Feb 23, 2018 at 10:35:58PM +0800, Jin Yao wrote: Unlike the perf report interactive annotate mode, the perf annotate doesn't display the LBR data. perf record -b ... perf annotate function It should show IPC/cycle, but it doesn't

Re: [PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-23 Thread Jin, Yao
On 2/23/2018 4:25 PM, Peter Zijlstra wrote: On Fri, Feb 23, 2018 at 10:35:58PM +0800, Jin Yao wrote: Unlike the perf report interactive annotate mode, the perf annotate doesn't display the LBR data. perf record -b ... perf annotate function It should show IPC/cycle, but it doesn't

[PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-22 Thread Jin Yao
Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/builtin-annotate.c | 88 --- 1 file changed, 82 insertions(+), 6 deletions(-) diff --git a/tools/perf/builtin-annotate.c b/tools/perf/builtin-annotate.c index f15731a..ead6ae4 100644

[PATCH] perf annotate: Support to display the LBR data in tui mode

2018-02-22 Thread Jin Yao
% 2; : :return i; 27.02 : 40064f: shr$0x1f,%edx 0.15 : 400652: add%edx,%eax 1.24 : 400654: and$0x1,%eax 2.08 : 400657: sub%edx,%eax :} 25.26 : 400659: retq # -100.00% (p:100.00%) Signed-off-by:

[tip:perf/core] perf report: Fix wrong jump arrow

2018-02-17 Thread tip-bot for Jin Yao
Commit-ID: b40982e8468b46b8f7f5bba5a7e541ec04a29d7d Gitweb: https://git.kernel.org/tip/b40982e8468b46b8f7f5bba5a7e541ec04a29d7d Author: Jin Yao <yao@linux.intel.com> AuthorDate: Mon, 29 Jan 2018 18:57:53 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf report: Fix wrong jump arrow

2018-02-17 Thread tip-bot for Jin Yao
Commit-ID: b40982e8468b46b8f7f5bba5a7e541ec04a29d7d Gitweb: https://git.kernel.org/tip/b40982e8468b46b8f7f5bba5a7e541ec04a29d7d Author: Jin Yao AuthorDate: Mon, 29 Jan 2018 18:57:53 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Fri, 16 Feb 2018 14:55:47 -0300 perf report: Fix

[tip:perf/core] perf tools: Use target->per_thread and target->system_wide flags

2018-02-17 Thread tip-bot for Jin Yao
Commit-ID: 147c508f3004df6e2958f6c8867909531c2a15e2 Gitweb: https://git.kernel.org/tip/147c508f3004df6e2958f6c8867909531c2a15e2 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Mon, 12 Feb 2018 13:32:36 -0700 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf tools: Use target->per_thread and target->system_wide flags

2018-02-17 Thread tip-bot for Jin Yao
Commit-ID: 147c508f3004df6e2958f6c8867909531c2a15e2 Gitweb: https://git.kernel.org/tip/147c508f3004df6e2958f6c8867909531c2a15e2 Author: Jin Yao AuthorDate: Mon, 12 Feb 2018 13:32:36 -0700 Committer: Arnaldo Carvalho de Melo CommitDate: Fri, 16 Feb 2018 14:55:40 -0300 perf tools: Use

Re: [PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-15 Thread Jin, Yao
On 2/13/2018 10:00 PM, Jin, Yao wrote: On 2/13/2018 5:45 PM, Jiri Olsa wrote: On Tue, Feb 13, 2018 at 04:44:28PM +0800, Jin Yao wrote: Following command lines will cause perf crash. perf record -j call -g -a perf report --branch-history *** Error in `perf': double free or corruption

Re: [PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-15 Thread Jin, Yao
On 2/13/2018 10:00 PM, Jin, Yao wrote: On 2/13/2018 5:45 PM, Jiri Olsa wrote: On Tue, Feb 13, 2018 at 04:44:28PM +0800, Jin Yao wrote: Following command lines will cause perf crash. perf record -j call -g -a perf report --branch-history *** Error in `perf': double free or corruption

Re: [PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-13 Thread Jin, Yao
On 2/13/2018 5:45 PM, Jiri Olsa wrote: On Tue, Feb 13, 2018 at 04:44:28PM +0800, Jin Yao wrote: Following command lines will cause perf crash. perf record -j call -g -a perf report --branch-history *** Error in `perf': double free or corruption (!prev): 0x104aa040

Re: [PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-13 Thread Jin, Yao
On 2/13/2018 5:45 PM, Jiri Olsa wrote: On Tue, Feb 13, 2018 at 04:44:28PM +0800, Jin Yao wrote: Following command lines will cause perf crash. perf record -j call -g -a perf report --branch-history *** Error in `perf': double free or corruption (!prev): 0x104aa040

[PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-12 Thread Jin Yao
l reallocate array 'he_cache[]' in iter_next_cumulative_entry() if necessary (the case of too many nodes in callchain). Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/util/hist.c | 21 + 1 file changed, 21 insertions(+) diff --git a/tools/perf/util/hist.c

[PATCH] perf report: Fix a memory corrupton issue when enabling --branch-history

2018-02-12 Thread Jin Yao
l reallocate array 'he_cache[]' in iter_next_cumulative_entry() if necessary (the case of too many nodes in callchain). Signed-off-by: Jin Yao --- tools/perf/util/hist.c | 21 + 1 file changed, 21 insertions(+) diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c inde

Re: [PATCH] perf report: Fix wrong jump arrow

2018-02-12 Thread Jin, Yao
Hi Arnaldo, Thanks for applying the patch. Yes the issue only happens on skl+. The committer notes are very good and clear. Thanks Jin Yao On 2/9/2018 11:15 PM, Arnaldo Carvalho de Melo wrote: Em Mon, Jan 29, 2018 at 06:57:53PM +0800, Jin Yao escreveu: When we use perf report interactive

Re: [PATCH] perf report: Fix wrong jump arrow

2018-02-12 Thread Jin, Yao
Hi Arnaldo, Thanks for applying the patch. Yes the issue only happens on skl+. The committer notes are very good and clear. Thanks Jin Yao On 2/9/2018 11:15 PM, Arnaldo Carvalho de Melo wrote: Em Mon, Jan 29, 2018 at 06:57:53PM +0800, Jin Yao escreveu: When we use perf report interactive

[PATCH] perf report: Fix wrong jump arrow

2018-01-28 Thread Jin Yao
212; │ │ │ │s_randseed = time(0); │ │srand(s_randseed); │ │ │ │for (i = 0; i < 20; i++) { 1.37 │0.4882:└─→sub$0x1,%ebx 28.21 │0.4817 ↑ jne38 Signed-off-by: Jin Yao <yao@linux.intel.com> ---

[PATCH] perf report: Fix wrong jump arrow

2018-01-28 Thread Jin Yao
212; │ │ │ │s_randseed = time(0); │ │srand(s_randseed); │ │ │ │for (i = 0; i < 20; i++) { 1.37 │0.4882:└─→sub$0x1,%ebx 28.21 │0.4817 ↑ jne38 Signed-off-by: Jin Yao --- tools/perf/ui/browsers/anno

[PATCH v2] perf util: Use target->per_thread and target->system_wide flags

2018-01-23 Thread Jin Yao
amp; target->system_wide' as a condition to check for all threads case. v2: --- According to Jiri's comment, add description to explain why the patch uses 'target->per_thread && target->system_wide'. v2 doesn't have functional change. Signed-off-by: Jin Yao <yao

[PATCH v2] perf util: Use target->per_thread and target->system_wide flags

2018-01-23 Thread Jin Yao
amp; target->system_wide' as a condition to check for all threads case. v2: --- According to Jiri's comment, add description to explain why the patch uses 'target->per_thread && target->system_wide'. v2 doesn't have functional change. Signed-off-by: Jin Yao --- tools/perf/uti

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-23 Thread Jin, Yao
On 1/23/2018 10:40 PM, Jiri Olsa wrote: On Tue, Jan 23, 2018 at 07:02:44AM +0800, Jin, Yao wrote: SNIP threads = thread_map__new_str(target->pid, target->tid, target->uid, - target->per_thread); +

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-23 Thread Jin, Yao
On 1/23/2018 10:40 PM, Jiri Olsa wrote: On Tue, Jan 23, 2018 at 07:02:44AM +0800, Jin, Yao wrote: SNIP threads = thread_map__new_str(target->pid, target->tid, target->uid, - target->per_thread); +

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin, Yao
On 1/23/2018 7:56 AM, Mathieu Poirier wrote: On 22 January 2018 at 15:15, Jin Yao <yao@linux.intel.com> wrote: Mathieu Poirier reports issue in commit ("73c0ca1eee3d perf thread_map: Enumerate all threads from /proc") that it has negative impact on 'perf record --per

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin, Yao
On 1/23/2018 7:56 AM, Mathieu Poirier wrote: On 22 January 2018 at 15:15, Jin Yao wrote: Mathieu Poirier reports issue in commit ("73c0ca1eee3d perf thread_map: Enumerate all threads from /proc") that it has negative impact on 'perf record --per-thread'. It has the effect o

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin, Yao
On 1/23/2018 5:10 AM, Mathieu Poirier wrote: On 22 January 2018 at 15:15, Jin Yao <yao@linux.intel.com> wrote: Mathieu Poirier reports issue in commit ("73c0ca1eee3d perf thread_map: Enumerate all threads from /proc") that it has negative impact on 'perf record --per

Re: [PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin, Yao
On 1/23/2018 5:10 AM, Mathieu Poirier wrote: On 22 January 2018 at 15:15, Jin Yao wrote: Mathieu Poirier reports issue in commit ("73c0ca1eee3d perf thread_map: Enumerate all threads from /proc") that it has negative impact on 'perf record --per-thread'. It has the effect o

[PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin Yao
amp; target->system_wide' as a condition to check for all threads case. Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/util/evlist.c | 2 +- tools/perf/util/thread_map.c | 4 ++-- tools/perf/util/thread_map.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff -

[PATCH] perf util: Use target->per_thread and target->system_wide flags

2018-01-22 Thread Jin Yao
amp; target->system_wide' as a condition to check for all threads case. Signed-off-by: Jin Yao --- tools/perf/util/evlist.c | 2 +- tools/perf/util/thread_map.c | 4 ++-- tools/perf/util/thread_map.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/perf/util/evlist

Re: [PATCH 1/1] perf util: Do not reuse target->per_thread flag

2018-01-22 Thread Jin, Yao
e. I just think for your perf record case, the target->system_wide will not be set. Instead, if target->per-thread and target->system_wide are both set, that means we needs to trace on all threads, right? Thanks Jin Yao On 1/13/2018 7:12 AM, Mathieu Poirier wrote: Commit ("73c0ca1e

Re: [PATCH 1/1] perf util: Do not reuse target->per_thread flag

2018-01-22 Thread Jin, Yao
e. I just think for your perf record case, the target->system_wide will not be set. Instead, if target->per-thread and target->system_wide are both set, that means we needs to trace on all threads, right? Thanks Jin Yao On 1/13/2018 7:12 AM, Mathieu Poirier wrote: Commit ("73c0ca1e

Re: [PATCH] perf util: Fix evlist->threads when working with 'perf stat --per-thread'

2018-01-22 Thread Jin, Yao
Very sorry, I just see this mail today. Please let me look at this issue first. Thanks Jin Yao threads in a system, resulting in new kernel events being created for all threads rather than just the thread of interest. This patch keeps the newly introduced functionality but make sure it doesn't

Re: [PATCH] perf util: Fix evlist->threads when working with 'perf stat --per-thread'

2018-01-22 Thread Jin, Yao
Very sorry, I just see this mail today. Please let me look at this issue first. Thanks Jin Yao threads in a system, resulting in new kernel events being created for all threads rather than just the thread of interest. This patch keeps the newly introduced functionality but make sure it doesn't

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-21 Thread Jin, Yao
On 1/16/2018 9:17 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 09:06:09PM +0800, Jin, Yao wrote: Just tested. But looks it's not OK for '--per-thread' case. yea, I haven't tested much.. might need soem tweaking, but my point was that it could be doable on one place instead of introducing

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-21 Thread Jin, Yao
On 1/16/2018 9:17 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 09:06:09PM +0800, Jin, Yao wrote: Just tested. But looks it's not OK for '--per-thread' case. yea, I haven't tested much.. might need soem tweaking, but my point was that it could be doable on one place instead of introducing

[tip:perf/core] perf script: Remove the time slices number limitation

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: cc2ef584a863b7c8033b78723cd253ca47e9a589 Gitweb: https://git.kernel.org/tip/cc2ef584a863b7c8033b78723cd253ca47e9a589 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:33 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf script: Remove the time slices number limitation

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: cc2ef584a863b7c8033b78723cd253ca47e9a589 Gitweb: https://git.kernel.org/tip/cc2ef584a863b7c8033b78723cd253ca47e9a589 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:33 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:37 -0300 perf script

[tip:perf/core] perf report: Remove the time slices number limitation

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 0a3cc3ae05c363dabd891ed5f918c62197de8c7f Gitweb: https://git.kernel.org/tip/0a3cc3ae05c363dabd891ed5f918c62197de8c7f Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:32 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf report: Remove the time slices number limitation

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 0a3cc3ae05c363dabd891ed5f918c62197de8c7f Gitweb: https://git.kernel.org/tip/0a3cc3ae05c363dabd891ed5f918c62197de8c7f Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:32 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:37 -0300 perf report

[tip:perf/core] perf util: Allocate time slices buffer according to number of comma

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 5a031f887cb8d60fe87d21159c3cf82c38f55679 Gitweb: https://git.kernel.org/tip/5a031f887cb8d60fe87d21159c3cf82c38f55679 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:31 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf util: Allocate time slices buffer according to number of comma

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 5a031f887cb8d60fe87d21159c3cf82c38f55679 Gitweb: https://git.kernel.org/tip/5a031f887cb8d60fe87d21159c3cf82c38f55679 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:31 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:36 -0300 perf util

[tip:perf/core] perf report: Add an indication of what time slices are used

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 7425664bbd3174814500c7ab8740cbb9bb25396c Gitweb: https://git.kernel.org/tip/7425664bbd3174814500c7ab8740cbb9bb25396c Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:30 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf report: Add an indication of what time slices are used

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 7425664bbd3174814500c7ab8740cbb9bb25396c Gitweb: https://git.kernel.org/tip/7425664bbd3174814500c7ab8740cbb9bb25396c Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:30 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:36 -0300 perf report: Add

[tip:perf/core] perf util: Support no index time percent slice

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 3002812e602d3f991a5b8cdc0499e63e13ff65c4 Gitweb: https://git.kernel.org/tip/3002812e602d3f991a5b8cdc0499e63e13ff65c4 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:29 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf util: Support no index time percent slice

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 3002812e602d3f991a5b8cdc0499e63e13ff65c4 Gitweb: https://git.kernel.org/tip/3002812e602d3f991a5b8cdc0499e63e13ff65c4 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:29 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:35 -0300 perf util

[tip:perf/core] perf util: Improve error checking for time percent input

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 6e761cbc9127fb8fc609aea2265ee8279b8d6c55 Gitweb: https://git.kernel.org/tip/6e761cbc9127fb8fc609aea2265ee8279b8d6c55 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:28 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf util: Improve error checking for time percent input

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 6e761cbc9127fb8fc609aea2265ee8279b8d6c55 Gitweb: https://git.kernel.org/tip/6e761cbc9127fb8fc609aea2265ee8279b8d6c55 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:28 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:35 -0300 perf util

[tip:perf/core] perf script: Improve error msg when no first/last sample time found

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 1e2778e91616086177a255f3fc8c72ecaa564ae6 Gitweb: https://git.kernel.org/tip/1e2778e91616086177a255f3fc8c72ecaa564ae6 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:27 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf script: Improve error msg when no first/last sample time found

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: 1e2778e91616086177a255f3fc8c72ecaa564ae6 Gitweb: https://git.kernel.org/tip/1e2778e91616086177a255f3fc8c72ecaa564ae6 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:27 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:34 -0300 perf script

[tip:perf/core] perf report: Improve error msg when no first/last sample time found

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: eb0b419eff8cf51af8e16cc8c5d2a92d19824266 Gitweb: https://git.kernel.org/tip/eb0b419eff8cf51af8e16cc8c5d2a92d19824266 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Wed, 10 Jan 2018 23:00:26 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> CommitD

[tip:perf/core] perf report: Improve error msg when no first/last sample time found

2018-01-17 Thread tip-bot for Jin Yao
Commit-ID: eb0b419eff8cf51af8e16cc8c5d2a92d19824266 Gitweb: https://git.kernel.org/tip/eb0b419eff8cf51af8e16cc8c5d2a92d19824266 Author: Jin Yao AuthorDate: Wed, 10 Jan 2018 23:00:26 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 17 Jan 2018 10:23:34 -0300 perf report

Re: [PATCH v1 0/8] perf: Follow-up patches to improve time slice

2018-01-16 Thread Jin, Yao
On 1/16/2018 10:48 PM, Arnaldo Carvalho de Melo wrote: Em Tue, Jan 16, 2018 at 12:55:19PM +0100, Jiri Olsa escreveu: On Wed, Jan 10, 2018 at 11:00:25PM +0800, Jin Yao wrote: It's follow-up patches to improve the perf time slice feature (perf report/script --time xxx) 1. Improve the error

Re: [PATCH v1 0/8] perf: Follow-up patches to improve time slice

2018-01-16 Thread Jin, Yao
On 1/16/2018 10:48 PM, Arnaldo Carvalho de Melo wrote: Em Tue, Jan 16, 2018 at 12:55:19PM +0100, Jiri Olsa escreveu: On Wed, Jan 10, 2018 at 11:00:25PM +0800, Jin Yao wrote: It's follow-up patches to improve the perf time slice feature (perf report/script --time xxx) 1. Improve the error

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-16 Thread Jin, Yao
On 1/16/2018 9:17 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 09:06:09PM +0800, Jin, Yao wrote: Just tested. But looks it's not OK for '--per-thread' case. yea, I haven't tested much.. might need soem tweaking, but my point was that it could be doable on one place instead of introducing

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-16 Thread Jin, Yao
On 1/16/2018 9:17 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 09:06:09PM +0800, Jin, Yao wrote: Just tested. But looks it's not OK for '--per-thread' case. yea, I haven't tested much.. might need soem tweaking, but my point was that it could be doable on one place instead of introducing

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-16 Thread Jin, Yao
Disallow kernel profiling by users without CAP_SYS_ADMIN To make this setting permanent, edit /etc/sysctl.conf too, e.g.: kernel.perf_event_paranoid = -1 Thanks Jin Yao On 1/16/2018 8:51 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 11:43:08PM +0800, Jin Yao wrote: If we execute 'perf s

Re: [PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-16 Thread Jin, Yao
Disallow kernel profiling by users without CAP_SYS_ADMIN To make this setting permanent, edit /etc/sysctl.conf too, e.g.: kernel.perf_event_paranoid = -1 Thanks Jin Yao On 1/16/2018 8:51 PM, Jiri Olsa wrote: On Tue, Jan 16, 2018 at 11:43:08PM +0800, Jin Yao wrote: If we execute 'perf s

Re: [PATCH v1 0/8] perf: Follow-up patches to improve time slice

2018-01-16 Thread Jin, Yao
On 1/16/2018 7:55 PM, Jiri Olsa wrote: On Wed, Jan 10, 2018 at 11:00:25PM +0800, Jin Yao wrote: It's follow-up patches to improve the perf time slice feature (perf report/script --time xxx) 1. Improve the error message perf report: Improve error msg when no first/last sample time found

Re: [PATCH v1 0/8] perf: Follow-up patches to improve time slice

2018-01-16 Thread Jin, Yao
On 1/16/2018 7:55 PM, Jiri Olsa wrote: On Wed, Jan 10, 2018 at 11:00:25PM +0800, Jin Yao wrote: It's follow-up patches to improve the perf time slice feature (perf report/script --time xxx) 1. Improve the error message perf report: Improve error msg when no first/last sample time found

[PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-15 Thread Jin Yao
d Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/builtin-stat.c| 14 +- tools/perf/util/evsel.c | 3 +++ tools/perf/util/thread_map.c | 1 + tools/perf/util/thread_map.h | 1 + 4 files changed, 18 insertions(+), 1 deletion(-) diff --git a/tools/perf/b

[PATCH] perf stat: Ignore error thread when enabling system-wide --per-thread

2018-01-15 Thread Jin Yao
d Signed-off-by: Jin Yao --- tools/perf/builtin-stat.c| 14 +- tools/perf/util/evsel.c | 3 +++ tools/perf/util/thread_map.c | 1 + tools/perf/util/thread_map.h | 1 + 4 files changed, 18 insertions(+), 1 deletion(-) diff --git a/tools/perf/builtin-stat.c b/tools/per

Re: [PATCH] perf util: Display warning when perf report/annotate is missing some libs

2018-01-11 Thread Jin, Yao
On 1/11/2018 11:30 PM, Jiri Olsa wrote: On Thu, Jan 11, 2018 at 07:03:06PM +0800, Jin Yao wrote: We keep having bug reports that when users build perf on their own, we already have same warnings during the build Yes, there will be warnings displayed during the build if some libraries

Re: [PATCH] perf util: Display warning when perf report/annotate is missing some libs

2018-01-11 Thread Jin, Yao
On 1/11/2018 11:30 PM, Jiri Olsa wrote: On Thu, Jan 11, 2018 at 07:03:06PM +0800, Jin Yao wrote: We keep having bug reports that when users build perf on their own, we already have same warnings during the build Yes, there will be warnings displayed during the build if some libraries

[tip:perf/core] perf script: Support time percent and multiple time ranges

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 2ab046cd01e33a854798a3e245c9e3f32b950a7d Gitweb: https://git.kernel.org/tip/2ab046cd01e33a854798a3e245c9e3f32b950a7d Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:46 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf script: Support time percent and multiple time ranges

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 2ab046cd01e33a854798a3e245c9e3f32b950a7d Gitweb: https://git.kernel.org/tip/2ab046cd01e33a854798a3e245c9e3f32b950a7d Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:46 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 12:07:06 -0300 perf script

[tip:perf/core] perf report: Support time percent and multiple time ranges

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 5b969bc766807e5c2f184d1d6f97b8471de946f1 Gitweb: https://git.kernel.org/tip/5b969bc766807e5c2f184d1d6f97b8471de946f1 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:45 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf report: Support time percent and multiple time ranges

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 5b969bc766807e5c2f184d1d6f97b8471de946f1 Gitweb: https://git.kernel.org/tip/5b969bc766807e5c2f184d1d6f97b8471de946f1 Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:45 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 12:06:20 -0300 perf report

[tip:perf/core] perf tools: Create function to perform multiple time range checking

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 9a9b8b4b2271e763c1600311a3d4ecc2ac359b55 Gitweb: https://git.kernel.org/tip/9a9b8b4b2271e763c1600311a3d4ecc2ac359b55 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:44 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf tools: Create function to perform multiple time range checking

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 9a9b8b4b2271e763c1600311a3d4ecc2ac359b55 Gitweb: https://git.kernel.org/tip/9a9b8b4b2271e763c1600311a3d4ecc2ac359b55 Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:44 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:41:06 -0300 perf tools: Create

[tip:perf/core] perf tools: Create function to parse time percent

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 13a70f350665580708ab11f725d3578eaacbf2d0 Gitweb: https://git.kernel.org/tip/13a70f350665580708ab11f725d3578eaacbf2d0 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:43 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf tools: Create function to parse time percent

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 13a70f350665580708ab11f725d3578eaacbf2d0 Gitweb: https://git.kernel.org/tip/13a70f350665580708ab11f725d3578eaacbf2d0 Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:43 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:39:09 -0300 perf tools: Create

[tip:perf/core] perf header: Add infrastructure to record first and last sample time

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 6011518db3bd04c80cd3ce3e6aea1c399739adb4 Gitweb: https://git.kernel.org/tip/6011518db3bd04c80cd3ce3e6aea1c399739adb4 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:41 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf record: Record the first and last sample time in the header

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 68588baf8d01826673f2874f434123029e519052 Gitweb: https://git.kernel.org/tip/68588baf8d01826673f2874f434123029e519052 Author: Jin Yao <yao@linux.intel.com> AuthorDate: Fri, 8 Dec 2017 21:13:42 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf header: Add infrastructure to record first and last sample time

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 6011518db3bd04c80cd3ce3e6aea1c399739adb4 Gitweb: https://git.kernel.org/tip/6011518db3bd04c80cd3ce3e6aea1c399739adb4 Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:41 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:20:51 -0300 perf header: Add

[tip:perf/core] perf record: Record the first and last sample time in the header

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 68588baf8d01826673f2874f434123029e519052 Gitweb: https://git.kernel.org/tip/68588baf8d01826673f2874f434123029e519052 Author: Jin Yao AuthorDate: Fri, 8 Dec 2017 21:13:42 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:20:56 -0300 perf record: Record

[tip:perf/core] perf report: Fix a wrong offset issue when using /proc/kcore

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 935f5a9d4500020879858c9224c98dfabf16101d Gitweb: https://git.kernel.org/tip/935f5a9d4500020879858c9224c98dfabf16101d Author: Jin Yao <yao@linux.intel.com> AuthorDate: Sat, 30 Dec 2017 00:26:52 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf report: Fix a no annotate browser displayed issue

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 40c39e3046411f84bab82f66783ff3593e2bcd9b Gitweb: https://git.kernel.org/tip/40c39e3046411f84bab82f66783ff3593e2bcd9b Author: Jin Yao <yao@linux.intel.com> AuthorDate: Tue, 26 Dec 2017 18:42:43 +0800 Committer: Arnaldo Carvalho de Melo <a...@redhat.com> Commit

[tip:perf/core] perf report: Fix a no annotate browser displayed issue

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 40c39e3046411f84bab82f66783ff3593e2bcd9b Gitweb: https://git.kernel.org/tip/40c39e3046411f84bab82f66783ff3593e2bcd9b Author: Jin Yao AuthorDate: Tue, 26 Dec 2017 18:42:43 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:11:57 -0300 perf report: Fix

[tip:perf/core] perf report: Fix a wrong offset issue when using /proc/kcore

2018-01-10 Thread tip-bot for Jin Yao
Commit-ID: 935f5a9d4500020879858c9224c98dfabf16101d Gitweb: https://git.kernel.org/tip/935f5a9d4500020879858c9224c98dfabf16101d Author: Jin Yao AuthorDate: Sat, 30 Dec 2017 00:26:52 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 8 Jan 2018 11:11:57 -0300 perf report: Fix

[PATCH] perf util: Display warning when perf report/annotate is missing some libs

2018-01-10 Thread Jin Yao
. This patch displays warnings that these libraries are missing in build when perf report / perf annotate are used. Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/builtin-annotate.c | 2 ++ tools/perf/builtin-report.c | 2 ++ tools/perf/util/symbol.c

[PATCH] perf util: Display warning when perf report/annotate is missing some libs

2018-01-10 Thread Jin Yao
. This patch displays warnings that these libraries are missing in build when perf report / perf annotate are used. Signed-off-by: Jin Yao --- tools/perf/builtin-annotate.c | 2 ++ tools/perf/builtin-report.c | 2 ++ tools/perf/util/symbol.c | 21 + tools/perf/util/symbol.h

[PATCH v1 6/8] perf util: Allocate time slices buffer according to number of comma

2018-01-09 Thread Jin Yao
entry even if no comma is found. Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/util/time-utils.c | 28 tools/perf/util/time-utils.h | 2 ++ 2 files changed, 30 insertions(+) diff --git a/tools/perf/util/time-utils.c b/tools/perf/util/time-utils.c

[PATCH v1 6/8] perf util: Allocate time slices buffer according to number of comma

2018-01-09 Thread Jin Yao
entry even if no comma is found. Signed-off-by: Jin Yao --- tools/perf/util/time-utils.c | 28 tools/perf/util/time-utils.h | 2 ++ 2 files changed, 30 insertions(+) diff --git a/tools/perf/util/time-utils.c b/tools/perf/util/time-utils.c index 5769f97..6193b46 100644

[PATCH v1 4/8] perf util: Support no index time percent slice

2018-01-09 Thread Jin Yao
Previously, the time percent slice needs an index to specify which one the user wants. While it may be easy for using if the index can be omitted. So with this patch, for example, perf report --stdio --time 10%/1 should be equivalent to perf report --stdio --time 10% Signed-off-by: Jin Yao <

[PATCH v1 2/8] perf script: Improve error msg when no first/last sample time found

2018-01-09 Thread Jin Yao
needs to set '--timestamp-boundary')." Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/builtin-script.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c index c1cce47..4f691af 100644 --- a/to

[PATCH v1 4/8] perf util: Support no index time percent slice

2018-01-09 Thread Jin Yao
Previously, the time percent slice needs an index to specify which one the user wants. While it may be easy for using if the index can be omitted. So with this patch, for example, perf report --stdio --time 10%/1 should be equivalent to perf report --stdio --time 10% Signed-off-by: Jin Yao

[PATCH v1 2/8] perf script: Improve error msg when no first/last sample time found

2018-01-09 Thread Jin Yao
needs to set '--timestamp-boundary')." Signed-off-by: Jin Yao --- tools/perf/builtin-script.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c index c1cce47..4f691af 100644 --- a/tools/perf/builtin-script.c +++ b/

[PATCH v1 8/8] perf script: Remove the time slices number limitation

2018-01-09 Thread Jin Yao
Previously it was only allowed to use at most 10 time slices in 'perf script --time'. This patch removes this limitation. For example, following command line is OK (12 time slices) perf script --time 1%/1,1%/2,1%/3,1%/4,1%/5,1%/6,1%/7,1%/8,1%/9,1%/10,1%/11,1%/12 Signed-off-by: Jin Yao <

[PATCH v1 8/8] perf script: Remove the time slices number limitation

2018-01-09 Thread Jin Yao
Previously it was only allowed to use at most 10 time slices in 'perf script --time'. This patch removes this limitation. For example, following command line is OK (12 time slices) perf script --time 1%/1,1%/2,1%/3,1%/4,1%/5,1%/6,1%/7,1%/8,1%/9,1%/10,1%/11,1%/12 Signed-off-by: Jin Yao

[PATCH v1 7/8] perf report: Remove the time slices number limitation

2018-01-09 Thread Jin Yao
Previously it was only allowed to use at most 10 time slices in 'perf report --time'. This patch removes this limitation. For example, following command line is OK (12 time slices) perf report --stdio --time 1%/1,1%/2,1%/3,1%/4,1%/5,1%/6,1%/7,1%/8,1%/9,1%/10,1%/11,1%/12 Signed-off-by: Jin Yao

[PATCH v1 3/8] perf util: Improve error checking for time percent input

2018-01-09 Thread Jin Yao
/tmp# perf report --stdio --time 1abc%/1 Invalid time string Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/util/time-utils.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/perf/util/time-utils.c b/tools/perf/util/time-utils.c index 3f7f18f

[PATCH v1 7/8] perf report: Remove the time slices number limitation

2018-01-09 Thread Jin Yao
Previously it was only allowed to use at most 10 time slices in 'perf report --time'. This patch removes this limitation. For example, following command line is OK (12 time slices) perf report --stdio --time 1%/1,1%/2,1%/3,1%/4,1%/5,1%/6,1%/7,1%/8,1%/9,1%/10,1%/11,1%/12 Signed-off-by: Jin Yao

[PATCH v1 3/8] perf util: Improve error checking for time percent input

2018-01-09 Thread Jin Yao
/tmp# perf report --stdio --time 1abc%/1 Invalid time string Signed-off-by: Jin Yao --- tools/perf/util/time-utils.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/perf/util/time-utils.c b/tools/perf/util/time-utils.c index 3f7f18f..88510ab 100644 --- a/tools/perf

[PATCH v1 5/8] perf report: Add an indication of what time slices are used

2018-01-09 Thread Jin Yao
Add a time slices indication to the perf report header. For example, # perf report --stdio --time 10% # Total Lost Samples: 0 # # Samples: 9K of event 'cycles:ppp' (time slices: 10%) # Event count (approx.): 8951288803 Signed-off-by: Jin Yao <yao@linux.intel.com> --- tool

[PATCH v1 5/8] perf report: Add an indication of what time slices are used

2018-01-09 Thread Jin Yao
Add a time slices indication to the perf report header. For example, # perf report --stdio --time 10% # Total Lost Samples: 0 # # Samples: 9K of event 'cycles:ppp' (time slices: 10%) # Event count (approx.): 8951288803 Signed-off-by: Jin Yao --- tools/perf/builtin-report.c | 3

[PATCH v1 1/8] perf report: Improve error msg when no first/last sample time found

2018-01-09 Thread Jin Yao
needs to set '--timestamp-boundary')." Signed-off-by: Jin Yao <yao@linux.intel.com> --- tools/perf/builtin-report.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c index dd4df9a..a6c5cf2 100644 --- a/to

[PATCH v1 1/8] perf report: Improve error msg when no first/last sample time found

2018-01-09 Thread Jin Yao
needs to set '--timestamp-boundary')." Signed-off-by: Jin Yao --- tools/perf/builtin-report.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c index dd4df9a..a6c5cf2 100644 --- a/tools/perf/builtin-report.c +++ b/

[PATCH v1 0/8] perf: Follow-up patches to improve time slice

2018-01-09 Thread Jin Yao
limitation perf script: Remove the time slices number limitation Jin Yao (8): perf report: Improve error msg when no first/last sample time found perf script: Improve error msg when no first/last sample time found perf util: Improve error checking for time percent input perf util: Support

<    5   6   7   8   9   10   11   12   13   14   >