Re: perf tools: remove option --tail-synthesize ?

2018-11-21 Thread Wangnan (F)
On 2018/11/21 21:11, Arnaldo Carvalho de Melo wrote: > Em Wed, Nov 21, 2018 at 07:45:28AM +, Song Liu escreveu: >> Hi, >> >> I found perf-record --tail-synthesize without --overwrite breaks symbols >> for perf-script, perf-report, etc. For example: >> >> [root@]# ~/perf record -ag

Re: perf tools: remove option --tail-synthesize ?

2018-11-21 Thread Wangnan (F)
On 2018/11/21 21:11, Arnaldo Carvalho de Melo wrote: > Em Wed, Nov 21, 2018 at 07:45:28AM +, Song Liu escreveu: >> Hi, >> >> I found perf-record --tail-synthesize without --overwrite breaks symbols >> for perf-script, perf-report, etc. For example: >> >> [root@]# ~/perf record -ag

Re: [tools/perf] perf test LLVM failure on 4.9

2018-01-23 Thread Wangnan (F)
On 2018/1/23 20:37, Pintu Kumar wrote: Hi All, I am verifying all perf tests on Ubuntu-16 x86-64 platform using the kernel version 4.9.20. I have installed several others packages including: clang, llvm But, when I run 'perf test' I get some FAILURE. Specially, 'perf test LLVM' is failing.

Re: [tools/perf] perf test LLVM failure on 4.9

2018-01-23 Thread Wangnan (F)
On 2018/1/23 20:37, Pintu Kumar wrote: Hi All, I am verifying all perf tests on Ubuntu-16 x86-64 platform using the kernel version 4.9.20. I have installed several others packages including: clang, llvm But, when I run 'perf test' I get some FAILURE. Specially, 'perf test LLVM' is failing.

Re: perf test BPF failing on 4.15.0-rc6

2018-01-03 Thread Wangnan (F)
On 2018/1/4 4:13, Arnaldo Carvalho de Melo wrote: Em Wed, Jan 03, 2018 at 03:33:07PM -0300, Arnaldo Carvalho de Melo escreveu: Em Wed, Jan 03, 2018 at 03:27:01PM -0300, Arnaldo Carvalho de Melo escreveu: Continuing investigation... After applying the fallback patch to allow new tools to

Re: perf test BPF failing on 4.15.0-rc6

2018-01-03 Thread Wangnan (F)
On 2018/1/4 4:13, Arnaldo Carvalho de Melo wrote: Em Wed, Jan 03, 2018 at 03:33:07PM -0300, Arnaldo Carvalho de Melo escreveu: Em Wed, Jan 03, 2018 at 03:27:01PM -0300, Arnaldo Carvalho de Melo escreveu: Continuing investigation... After applying the fallback patch to allow new tools to

Re: perf test BPF failing on 4.15.0-rc6

2018-01-02 Thread Wangnan (F)
ord: Captured and wrote 0.016 MB perf.data (100 samples) ] I guess in your configuration you would get 3 tracepoints, and can get 0 sample from them. Thank you. On 2018/1/3 12:42, Wangnan (F) wrote: Unable to reproduce. In my kernel configuration, SyS_epoll_wait is not inlined at all. From the

Re: perf test BPF failing on 4.15.0-rc6

2018-01-02 Thread Wangnan (F)
ord: Captured and wrote 0.016 MB perf.data (100 samples) ] I guess in your configuration you would get 3 tracepoints, and can get 0 sample from them. Thank you. On 2018/1/3 12:42, Wangnan (F) wrote: Unable to reproduce. In my kernel configuration, SyS_epoll_wait is not inlined at all. From the

Re: perf test BPF failing on 4.15.0-rc6

2018-01-02 Thread Wangnan (F)
Unable to reproduce. In my kernel configuration, SyS_epoll_wait is not inlined at all. From the log you sent, it seems that all 3 instances are attached. This testcase should work if the last one (SyS_epoll_wait) get probed correctly. Could you please have a look if the 3rd kprobe event

Re: perf test BPF failing on 4.15.0-rc6

2018-01-02 Thread Wangnan (F)
Unable to reproduce. In my kernel configuration, SyS_epoll_wait is not inlined at all. From the log you sent, it seems that all 3 instances are attached. This testcase should work if the last one (SyS_epoll_wait) get probed correctly. Could you please have a look if the 3rd kprobe event

Re: Php-fpm will crash when perf runs with call graph option

2017-12-24 Thread Wangnan (F)
Have you tried updating your kernel to a recent version? On 2017/12/25 14:58, ufo19890607 wrote: From: yuzhoujian I use perf to analyze the performance overhead for the server. There are several dockers in the server. The php-fpm in the docker will crash as long

Re: Php-fpm will crash when perf runs with call graph option

2017-12-24 Thread Wangnan (F)
Have you tried updating your kernel to a recent version? On 2017/12/25 14:58, ufo19890607 wrote: From: yuzhoujian I use perf to analyze the performance overhead for the server. There are several dockers in the server. The php-fpm in the docker will crash as long as the perf collects samples

Re: [PATCH V2 2/8] perf tools: rewrite perf mmap read for overwrite

2017-12-18 Thread Wangnan (F)
On 2017/12/19 3:07, Liang, Kan wrote: -union perf_event *perf_mmap__read_backward(struct perf_mmap *map) +union perf_event *perf_mmap__read_backward(struct perf_mmap *map, + u64 *start, u64 end) { - u64 head, end; - u64 start = map->prev;

Re: [PATCH V2 2/8] perf tools: rewrite perf mmap read for overwrite

2017-12-18 Thread Wangnan (F)
On 2017/12/19 3:07, Liang, Kan wrote: -union perf_event *perf_mmap__read_backward(struct perf_mmap *map) +union perf_event *perf_mmap__read_backward(struct perf_mmap *map, + u64 *start, u64 end) { - u64 head, end; - u64 start = map->prev;

Re: [PATCH V2 6/8] perf top: add overwrite fall back

2017-12-18 Thread Wangnan (F)
On 2017/12/7 7:33, kan.li...@intel.com wrote: From: Kan Liang Switch to non-overwrite mode if kernel doesnot support overwrite ringbuffer. It's only effect when overwrite mode is supported. No change to current behavior. Signed-off-by: Kan Liang

Re: [PATCH V2 6/8] perf top: add overwrite fall back

2017-12-18 Thread Wangnan (F)
On 2017/12/7 7:33, kan.li...@intel.com wrote: From: Kan Liang Switch to non-overwrite mode if kernel doesnot support overwrite ringbuffer. It's only effect when overwrite mode is supported. No change to current behavior. Signed-off-by: Kan Liang --- tools/perf/builtin-top.c | 35

Re: [PATCH V2 2/8] perf tools: rewrite perf mmap read for overwrite

2017-12-18 Thread Wangnan (F)
On 2017/12/7 7:32, kan.li...@intel.com wrote: From: Kan Liang perf_mmap__read_catchup and perf_mmap__read_backward are used to read events one by one from ring buffer under overwrite mode. It always read the stale buffer which is already processed. Because the previous

Re: [PATCH V2 2/8] perf tools: rewrite perf mmap read for overwrite

2017-12-18 Thread Wangnan (F)
On 2017/12/7 7:32, kan.li...@intel.com wrote: From: Kan Liang perf_mmap__read_catchup and perf_mmap__read_backward are used to read events one by one from ring buffer under overwrite mode. It always read the stale buffer which is already processed. Because the previous location of processed

Re: [PATCH V2 1/8] perf tools: remove stale perf evlist mmap read for backward

2017-12-17 Thread Wangnan (F)
On 2017/12/7 7:32, kan.li...@intel.com wrote: From: Kan Liang perf_evlist__mmap_read_catchup and perf_evlist__mmap_read_backward are only for overwrite mode. But they read the evlist->mmap buffer which is for non-overwrite mode. It did not bring any serious problem yet,

Re: [PATCH V2 1/8] perf tools: remove stale perf evlist mmap read for backward

2017-12-17 Thread Wangnan (F)
On 2017/12/7 7:32, kan.li...@intel.com wrote: From: Kan Liang perf_evlist__mmap_read_catchup and perf_evlist__mmap_read_backward are only for overwrite mode. But they read the evlist->mmap buffer which is for non-overwrite mode. It did not bring any serious problem yet, because there is no

Re: [PATCH 4/5] perf top: switch to overwrite mode

2017-12-05 Thread Wangnan (F)
On 2017/12/6 6:39, kan.li...@intel.com wrote: From: Kan Liang perf_top__mmap_read has severe performance issue in Knights Landing/Mill, when monitoring in heavy load system. It costs several minutes to finish, which is unacceptable. Currently, perf top is non overwrite

Re: [PATCH 4/5] perf top: switch to overwrite mode

2017-12-05 Thread Wangnan (F)
On 2017/12/6 6:39, kan.li...@intel.com wrote: From: Kan Liang perf_top__mmap_read has severe performance issue in Knights Landing/Mill, when monitoring in heavy load system. It costs several minutes to finish, which is unacceptable. Currently, perf top is non overwrite mode. For non

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 19:57, Michal Hocko wrote: On Mon 06-11-17 19:03:34, Wangnan (F) wrote: On 2017/11/6 18:40, Michal Hocko wrote: On Mon 06-11-17 17:59:54, Wangnan (F) wrote: On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 19:57, Michal Hocko wrote: On Mon 06-11-17 19:03:34, Wangnan (F) wrote: On 2017/11/6 18:40, Michal Hocko wrote: On Mon 06-11-17 17:59:54, Wangnan (F) wrote: On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 18:40, Michal Hocko wrote: On Mon 06-11-17 17:59:54, Wangnan (F) wrote: On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang Nan <wangn...@huawei.com> wrote: tlb_gather_mmu(, mm, 0, -1) means gatheri

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 18:40, Michal Hocko wrote: On Mon 06-11-17 17:59:54, Wangnan (F) wrote: On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang Nan wrote: tlb_gather_mmu(, mm, 0, -1) means gathering all virtual memory space

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang Nan wrote: tlb_gather_mmu(, mm, 0, -1) means gathering all virtual memory space. In this case, tlb->fullmm is true. Some archs like arm64 doesn't flush

Re: [RFC PATCH] mm, oom_reaper: gather each vma to prevent leaking TLB entry

2017-11-06 Thread Wangnan (F)
On 2017/11/6 16:52, Michal Hocko wrote: On Mon 06-11-17 15:04:40, Bob Liu wrote: On Mon, Nov 6, 2017 at 11:36 AM, Wang Nan wrote: tlb_gather_mmu(, mm, 0, -1) means gathering all virtual memory space. In this case, tlb->fullmm is true. Some archs like arm64 doesn't flush TLB when tlb->fullmm

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 21:57, Liang, Kan wrote: On 2017/11/1 20:00, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 06:32:50PM +0800, Wangnan (F) wrote: On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 21:57, Liang, Kan wrote: On 2017/11/1 20:00, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 06:32:50PM +0800, Wangnan (F) wrote: On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 23:04, Liang, Kan wrote: On 2017/11/1 22:22, Liang, Kan wrote: On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 23:04, Liang, Kan wrote: On 2017/11/1 22:22, Liang, Kan wrote: On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 22:22, Liang, Kan wrote: On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly (perf_evlist__mmap_ex's argument).

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 22:22, Liang, Kan wrote: On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly (perf_evlist__mmap_ex's argument).

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly (perf_evlist__mmap_ex's argument). 2. Set evsel's "backward" attribute (in

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 21:26, Liang, Kan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly (perf_evlist__mmap_ex's argument). 2. Set evsel's "backward" attribute (in

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 20:39, Jiri Olsa wrote: On Wed, Nov 01, 2017 at 08:10:49PM +0800, Wangnan (F) wrote: SNIP diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c index c6c891e154a6..27ebe355e794 100644 --- a/tools/perf/util/evlist.c +++ b/tools/perf/util/evlist.c @@ -838,6 +838,11

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 20:39, Jiri Olsa wrote: On Wed, Nov 01, 2017 at 08:10:49PM +0800, Wangnan (F) wrote: SNIP diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c index c6c891e154a6..27ebe355e794 100644 --- a/tools/perf/util/evlist.c +++ b/tools/perf/util/evlist.c @@ -838,6 +838,11

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 20:00, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 06:32:50PM +0800, Wangnan (F) wrote: On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work as we expected: it never overwrite when

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 20:00, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 06:32:50PM +0800, Wangnan (F) wrote: On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work as we expected: it never overwrite when

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work as we expected: it never overwrite when ring buffer full. Test: (Run a busy printing python task background like this: while True:

Re: [PATCH 1/2] perf mmap: Fix perf backward recording

2017-11-01 Thread Wangnan (F)
On 2017/11/1 17:49, Namhyung Kim wrote: Hi, On Wed, Nov 01, 2017 at 05:53:26AM +, Wang Nan wrote: perf record backward recording doesn't work as we expected: it never overwrite when ring buffer full. Test: (Run a busy printing python task background like this: while True:

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 18:03, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 05:53:27AM +, Wang Nan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly

Re: [PATCH 2/2] perf record: Replace 'overwrite' by 'flightrecorder' for better naming

2017-11-01 Thread Wangnan (F)
On 2017/11/1 18:03, Namhyung Kim wrote: On Wed, Nov 01, 2017 at 05:53:27AM +, Wang Nan wrote: The meaning of perf record's "overwrite" option and many "overwrite" in source code are not clear. In perf's code, the 'overwrite' has 2 meanings: 1. Make ringbuffer readonly

Re: [PATCH 2/2] perf, tools: Don't force MetricExprs to lower case

2017-10-12 Thread Wangnan (F)
On 2017/10/12 23:59, Jiri Olsa wrote: On Thu, Oct 12, 2017 at 11:31:51PM +0800, Wangnan (F) wrote: SNIP Ok. If it works it's fine for me. well it works, but it means that bpf file cannot contains any directory part.. which im not sure is ok with bpf folks ;-) anyone? Sorry I didn't see

Re: [PATCH 2/2] perf, tools: Don't force MetricExprs to lower case

2017-10-12 Thread Wangnan (F)
On 2017/10/12 23:59, Jiri Olsa wrote: On Thu, Oct 12, 2017 at 11:31:51PM +0800, Wangnan (F) wrote: SNIP Ok. If it works it's fine for me. well it works, but it means that bpf file cannot contains any directory part.. which im not sure is ok with bpf folks ;-) anyone? Sorry I didn't see

Re: [PATCH 2/2] perf, tools: Don't force MetricExprs to lower case

2017-10-12 Thread Wangnan (F)
On 2017/10/9 22:39, Jiri Olsa wrote: On Mon, Oct 09, 2017 at 11:12:58AM -0300, Arnaldo Carvalho de Melo wrote: Em Mon, Oct 09, 2017 at 07:07:29AM -0700, Andi Kleen escreveu: On Mon, Oct 09, 2017 at 03:41:51PM +0200, Jiri Olsa wrote: On Wed, Oct 04, 2017 at 09:27:11AM -0700, Andi Kleen

Re: [PATCH 2/2] perf, tools: Don't force MetricExprs to lower case

2017-10-12 Thread Wangnan (F)
On 2017/10/9 22:39, Jiri Olsa wrote: On Mon, Oct 09, 2017 at 11:12:58AM -0300, Arnaldo Carvalho de Melo wrote: Em Mon, Oct 09, 2017 at 07:07:29AM -0700, Andi Kleen escreveu: On Mon, Oct 09, 2017 at 03:41:51PM +0200, Jiri Olsa wrote: On Wed, Oct 04, 2017 at 09:27:11AM -0700, Andi Kleen

Re: [PATCH] perf tool: Don't discard prev in backward mode

2017-10-12 Thread Wangnan (F)
Hi Kan, Please see if this patch works for you. On 2017/10/14 7:16, Wang Nan wrote: Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the data from old output. That also brings extra

Re: [PATCH] perf tool: Don't discard prev in backward mode

2017-10-12 Thread Wangnan (F)
Hi Kan, Please see if this patch works for you. On 2017/10/14 7:16, Wang Nan wrote: Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the data from old output. That also brings extra

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 22:46, Wangnan (F) wrote: On 2017/10/12 22:45, Liang, Kan wrote: On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 22:46, Wangnan (F) wrote: On 2017/10/12 22:45, Liang, Kan wrote: On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 22:45, Liang, Kan wrote: On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time.

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 22:45, Liang, Kan wrote: On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time.

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-12 Thread Wangnan (F)
On 2017/10/12 20:49, Liang, Kan wrote: From 8b058ea6977a97e5705aa2f64bdd014fd76d1247 Mon Sep 17 00:00:00 2001 From: Kan Liang Date: Wed, 11 Oct 2017 07:39:34 -0700 Subject: [PATCH] perf tool: fix: Don't discard prev in backward mode Perf record can switch output. The

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-12 Thread Wangnan (F)
On 2017/10/12 20:49, Liang, Kan wrote: From 8b058ea6977a97e5705aa2f64bdd014fd76d1247 Mon Sep 17 00:00:00 2001 From: Kan Liang Date: Wed, 11 Oct 2017 07:39:34 -0700 Subject: [PATCH] perf tool: fix: Don't discard prev in backward mode Perf record can switch output. The new output should

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time. Overwriting is not triggered. This commit maps

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-12 Thread Wangnan (F)
On 2017/10/12 20:56, Liang, Kan wrote: On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time. Overwriting is not triggered. This commit maps

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-11 Thread Wangnan (F)
On 2017/10/11 22:57, Liang, Kan wrote: If you really want to avoid record duplication, you need to changes record__mmap_read()'s logic. Now it complains "failed to keep up with mmap data" and avoid dumping data when size of newly generated data is larger than the size of the ring buffer. It is

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-11 Thread Wangnan (F)
On 2017/10/11 22:57, Liang, Kan wrote: If you really want to avoid record duplication, you need to changes record__mmap_read()'s logic. Now it complains "failed to keep up with mmap data" and avoid dumping data when size of newly generated data is larger than the size of the ring buffer. It is

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-11 Thread Wangnan (F)
On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time. Overwriting is not triggered. This commit maps backward ring buffers readonly, make

Re: [PATCH] perf tools: fix: Force backward ring buffer mapped readonly

2017-10-11 Thread Wangnan (F)
On 2017/10/11 21:16, Liang, Kan wrote: perf record's --overwrite option doesn't work as we expect. For example: [SNIP] In the above example we get same records from the backward ring buffer all the time. Overwriting is not triggered. This commit maps backward ring buffers readonly, make

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:55, Liang, Kan wrote: On 2017/10/11 3:17, Arnaldo Carvalho de Melo wrote: Em Wed, Oct 11, 2017 at 03:10:37AM +0800, Wangnan (F) escreveu: On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:55, Liang, Kan wrote: On 2017/10/11 3:17, Arnaldo Carvalho de Melo wrote: Em Wed, Oct 11, 2017 at 03:10:37AM +0800, Wangnan (F) escreveu: On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:50, Liang, Kan wrote: On 2017/10/11 2:23, Wangnan (F) wrote: On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang <kan.li...@intel.com> Perf record can switch output. The new output should only store the data after switching. However, in overwrite backwar

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:50, Liang, Kan wrote: On 2017/10/11 2:23, Wangnan (F) wrote: On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:17, Arnaldo Carvalho de Melo wrote: Em Wed, Oct 11, 2017 at 03:10:37AM +0800, Wangnan (F) escreveu: On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 03:34:55PM -0300

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:17, Arnaldo Carvalho de Melo wrote: Em Wed, Oct 11, 2017 at 03:10:37AM +0800, Wangnan (F) escreveu: On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 03:34:55PM -0300

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 03:34:55PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 06:28:18PM +, Liang, Kan escreveu: Em Tue, Oct 10, 2017

Re: [PATCH 03/10] perf tool: new iterfaces to read event from ring buffer

2017-10-10 Thread Wangnan (F)
On 2017/10/11 3:00, Arnaldo Carvalho de Melo wrote: Em Tue, Oct 10, 2017 at 03:36:28PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 03:34:55PM -0300, Arnaldo Carvalho de Melo escreveu: Em Tue, Oct 10, 2017 at 06:28:18PM +, Liang, Kan escreveu: Em Tue, Oct 10, 2017

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 2:23, Wangnan (F) wrote: On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang <kan.li...@intel.com> Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the dat

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 2:23, Wangnan (F) wrote: On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the data from old output

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the data from old output. At the end of mmap_read, the

Re: [PATCH 02/10] perf tool: fix: Don't discard prev in backward mode

2017-10-10 Thread Wangnan (F)
On 2017/10/11 1:20, kan.li...@intel.com wrote: From: Kan Liang Perf record can switch output. The new output should only store the data after switching. However, in overwrite backward mode, the new output still have the data from old output. At the end of mmap_read, the position of

Re: [PATCHv2] perf bpf: Fix endianness problem when loading parameters in prologue

2017-08-15 Thread Wangnan (F)
On 2017/8/15 14:42, Thomas-Mich Richter wrote: On 08/14/2017 06:39 PM, Arnaldo Carvalho de Melo wrote: Em Mon, Aug 14, 2017 at 01:46:44PM +0200, Thomas Richter escreveu: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes problem on big endian

Re: [PATCHv2] perf bpf: Fix endianness problem when loading parameters in prologue

2017-08-15 Thread Wangnan (F)
On 2017/8/15 14:42, Thomas-Mich Richter wrote: On 08/14/2017 06:39 PM, Arnaldo Carvalho de Melo wrote: Em Mon, Aug 14, 2017 at 01:46:44PM +0200, Thomas Richter escreveu: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes problem on big endian

Re: perf bpf: Reworked fix endianness problem when loading parameters in prologue

2017-08-14 Thread Wangnan (F)
OK. On 2017/8/14 18:58, Thomas-Mich Richter wrote: On 08/14/2017 12:30 PM, Wangnan (F) wrote: Hi Thomas, Your patch looks good to me. I've tested in my environment and it works. Please resend it to lkml and let Arnaldo to collect it. Thank you. Will do, I take this as an Acked

Re: perf bpf: Reworked fix endianness problem when loading parameters in prologue

2017-08-14 Thread Wangnan (F)
OK. On 2017/8/14 18:58, Thomas-Mich Richter wrote: On 08/14/2017 12:30 PM, Wangnan (F) wrote: Hi Thomas, Your patch looks good to me. I've tested in my environment and it works. Please resend it to lkml and let Arnaldo to collect it. Thank you. Will do, I take this as an Acked

Re: perf bpf: Reworked fix endianness problem when loading parameters in prologue

2017-08-14 Thread Wangnan (F)
Hi Thomas, Your patch looks good to me. I've tested in my environment and it works. Please resend it to lkml and let Arnaldo to collect it. Thank you. On 2017/8/14 17:47, Thomas Richter wrote: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes

Re: perf bpf: Reworked fix endianness problem when loading parameters in prologue

2017-08-14 Thread Wangnan (F)
Hi Thomas, Your patch looks good to me. I've tested in my environment and it works. Please resend it to lkml and let Arnaldo to collect it. Thank you. On 2017/8/14 17:47, Thomas Richter wrote: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes

Re: [PATCH] perf bpf: Fix endianness problem when loading parameters in prologue

2017-08-11 Thread Wangnan (F)
Hi Thomas, Please try this patch on your machine and give me the result. Thank you. On 2017/8/13 2:49, Wang Nan wrote: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes problem on big endian machine. Thomas gives a detail analysis for this

Re: [PATCH] perf bpf: Fix endianness problem when loading parameters in prologue

2017-08-11 Thread Wangnan (F)
Hi Thomas, Please try this patch on your machine and give me the result. Thank you. On 2017/8/13 2:49, Wang Nan wrote: Perf BPF prologue generator unconditionally fetches 8 bytes for function parameters, which causes problem on big endian machine. Thomas gives a detail analysis for this

Re: perf test BPF subtest bpf-prologue test fails on s390x

2017-08-11 Thread Wangnan (F)
On 2017/8/11 17:17, Thomas-Mich Richter wrote: On 08/11/2017 07:19 AM, Wangnan (F) wrote: On 2017/8/11 2:13, Arnaldo Carvalho de Melo wrote: Thomas, please try to find who wrote that test and CC him, I'm doing it this time, Wang, can you please take a look at this? I also added lkml

Re: perf test BPF subtest bpf-prologue test fails on s390x

2017-08-11 Thread Wangnan (F)
On 2017/8/11 17:17, Thomas-Mich Richter wrote: On 08/11/2017 07:19 AM, Wangnan (F) wrote: On 2017/8/11 2:13, Arnaldo Carvalho de Melo wrote: Thomas, please try to find who wrote that test and CC him, I'm doing it this time, Wang, can you please take a look at this? I also added lkml

Re: perf test BPF subtest bpf-prologue test fails on s390x

2017-08-10 Thread Wangnan (F)
On 2017/8/11 2:13, Arnaldo Carvalho de Melo wrote: Thomas, please try to find who wrote that test and CC him, I'm doing it this time, Wang, can you please take a look at this? I also added lkml to the CC list, here we have more users of perf, lkml is the more developer centric perf list, as

Re: perf test BPF subtest bpf-prologue test fails on s390x

2017-08-10 Thread Wangnan (F)
On 2017/8/11 2:13, Arnaldo Carvalho de Melo wrote: Thomas, please try to find who wrote that test and CC him, I'm doing it this time, Wang, can you please take a look at this? I also added lkml to the CC list, here we have more users of perf, lkml is the more developer centric perf list, as

Re: change uprobe_events default ? Was: [PATCH] perf: Rename CONFIG_[UK]PROBE_EVENT to CONFIG_[UK]PROBE_EVENTS

2017-03-15 Thread Wangnan (F)
On 2017/3/16 9:06, Arnaldo Carvalho de Melo wrote: Added more people to the CC list. Em Wed, Mar 15, 2017 at 05:58:19PM -0700, Alexei Starovoitov escreveu: On Thu, Feb 16, 2017 at 05:00:50PM +1100, Anton Blanchard wrote: We have uses of CONFIG_UPROBE_EVENT and CONFIG_KPROBE_EVENT as well as

Re: change uprobe_events default ? Was: [PATCH] perf: Rename CONFIG_[UK]PROBE_EVENT to CONFIG_[UK]PROBE_EVENTS

2017-03-15 Thread Wangnan (F)
On 2017/3/16 9:06, Arnaldo Carvalho de Melo wrote: Added more people to the CC list. Em Wed, Mar 15, 2017 at 05:58:19PM -0700, Alexei Starovoitov escreveu: On Thu, Feb 16, 2017 at 05:00:50PM +1100, Anton Blanchard wrote: We have uses of CONFIG_UPROBE_EVENT and CONFIG_KPROBE_EVENT as well as

Re: [PATCH net-next v1] bpf: Remove redundant ifdef

2017-02-14 Thread Wangnan (F)
On 2017/2/15 1:07, David Miller wrote: From: "Wangnan (F)" <wangn...@huawei.com> Date: Mon, 13 Feb 2017 09:53:49 +0800 On 2017/2/12 3:37, Mickaël Salaün wrote: Remove a useless ifdef __NR_bpf as requested by Wang Nan. Inline one-line static functions as it was in th

Re: [PATCH net-next v1] bpf: Remove redundant ifdef

2017-02-14 Thread Wangnan (F)
On 2017/2/15 1:07, David Miller wrote: From: "Wangnan (F)" Date: Mon, 13 Feb 2017 09:53:49 +0800 On 2017/2/12 3:37, Mickaël Salaün wrote: Remove a useless ifdef __NR_bpf as requested by Wang Nan. Inline one-line static functions as it was in the bpf_sys.h file. Signed-off-b

Re: [PATCH net-next v1] bpf: Remove redundant ifdef

2017-02-12 Thread Wangnan (F)
On 2017/2/12 3:37, Mickaël Salaün wrote: Remove a useless ifdef __NR_bpf as requested by Wang Nan. Inline one-line static functions as it was in the bpf_sys.h file. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann

Re: [PATCH net-next v1] bpf: Remove redundant ifdef

2017-02-12 Thread Wangnan (F)
On 2017/2/12 3:37, Mickaël Salaün wrote: Remove a useless ifdef __NR_bpf as requested by Wang Nan. Inline one-line static functions as it was in the bpf_sys.h file. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: David S. Miller Cc: Wang Nan Link:

Re: [PATCH v4 0/3] Miscellaneous fixes for BPF (perf tree)

2017-02-12 Thread Wangnan (F)
On 2017/2/9 4:27, Mickaël Salaün wrote: This series brings some fixes and small improvements to the BPF samples. This is intended for the perf tree and apply on 7a5980f9c006 ("tools lib bpf: Add missing header to the library"). Changes since v3: * remove applied patch 1/5 * remove patch 2/5

Re: [PATCH v4 0/3] Miscellaneous fixes for BPF (perf tree)

2017-02-12 Thread Wangnan (F)
On 2017/2/9 4:27, Mickaël Salaün wrote: This series brings some fixes and small improvements to the BPF samples. This is intended for the perf tree and apply on 7a5980f9c006 ("tools lib bpf: Add missing header to the library"). Changes since v3: * remove applied patch 1/5 * remove patch 2/5

Re: [PATCH net-next v5 04/11] bpf: Use bpf_load_program() from the library

2017-02-09 Thread Wangnan (F)
On 2017/2/10 10:25, Wangnan (F) wrote: On 2017/2/10 7:21, Mickaël Salaün wrote: Replace bpf_prog_load() with bpf_load_program() calls. Signed-off-by: Mickaël Salaün <m...@digikod.net> Cc: Alexei Starovoitov <a...@fb.com> Cc: Daniel Borkmann <dan...@iogearbox.net>

Re: [PATCH net-next v5 04/11] bpf: Use bpf_load_program() from the library

2017-02-09 Thread Wangnan (F)
On 2017/2/10 10:25, Wangnan (F) wrote: On 2017/2/10 7:21, Mickaël Salaün wrote: Replace bpf_prog_load() with bpf_load_program() calls. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: Shuah Khan --- tools/lib/bpf/bpf.c | 6

Re: [PATCH net-next v5 10/11] bpf: Remove bpf_sys.h from selftests

2017-02-09 Thread Wangnan (F)
On 2017/2/10 7:21, Mickaël Salaün wrote: Add require dependency headers. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: Shuah Khan --- tools/lib/bpf/bpf.c | 6

Re: [PATCH net-next v5 10/11] bpf: Remove bpf_sys.h from selftests

2017-02-09 Thread Wangnan (F)
On 2017/2/10 7:21, Mickaël Salaün wrote: Add require dependency headers. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: Shuah Khan --- tools/lib/bpf/bpf.c | 6 ++ tools/testing/selftests/bpf/bpf_sys.h | 27

Re: [PATCH net-next v5 04/11] bpf: Use bpf_load_program() from the library

2017-02-09 Thread Wangnan (F)
On 2017/2/10 7:21, Mickaël Salaün wrote: Replace bpf_prog_load() with bpf_load_program() calls. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: Shuah Khan --- tools/lib/bpf/bpf.c

Re: [PATCH net-next v5 04/11] bpf: Use bpf_load_program() from the library

2017-02-09 Thread Wangnan (F)
On 2017/2/10 7:21, Mickaël Salaün wrote: Replace bpf_prog_load() with bpf_load_program() calls. Signed-off-by: Mickaël Salaün Cc: Alexei Starovoitov Cc: Daniel Borkmann Cc: Shuah Khan --- tools/lib/bpf/bpf.c | 6 +++--- tools/lib/bpf/bpf.h

  1   2   3   4   5   6   7   8   9   10   >