Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Song Liu
> On Aug 5, 2020, at 3:50 PM, Alexei Starovoitov > wrote: > > On Wed, Aug 05, 2020 at 06:56:26PM +, Song Liu wrote: >> >> >>> On Aug 5, 2020, at 10:16 AM, Alexei Starovoitov >>> wrote: >>> >>> On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: Being able to trigger

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Alexei Starovoitov
On Wed, Aug 05, 2020 at 06:56:26PM +, Song Liu wrote: > > > > On Aug 5, 2020, at 10:16 AM, Alexei Starovoitov > > wrote: > > > > On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: > >> > >> Being able to trigger BPF program on a different CPU could enable many > >> use cases and op

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Song Liu
> On Aug 5, 2020, at 10:39 AM, Andrii Nakryiko > wrote: > > On Wed, Aug 5, 2020 at 12:01 AM Song Liu wrote: >> >> >> >>> On Aug 4, 2020, at 10:47 PM, Andrii Nakryiko >>> wrote: >>> >>> On Tue, Aug 4, 2020 at 9:47 PM Song Liu wrote: > On Aug 4, 2020, at 6:52 PM, An

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Alexei Starovoitov
On Wed, Aug 05, 2020 at 10:27:28AM -0700, Andrii Nakryiko wrote: > On Wed, Aug 5, 2020 at 10:16 AM Alexei Starovoitov > wrote: > > > > On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: > > > > > > Being able to trigger BPF program on a different CPU could enable many > > > use cases and op

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Andrii Nakryiko
On Wed, Aug 5, 2020 at 10:45 AM Alexei Starovoitov wrote: > > On Wed, Aug 05, 2020 at 10:27:28AM -0700, Andrii Nakryiko wrote: > > On Wed, Aug 5, 2020 at 10:16 AM Alexei Starovoitov > > wrote: > > > > > > On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: > > > > > > > > Being able to trig

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Song Liu
> On Aug 5, 2020, at 10:16 AM, Alexei Starovoitov > wrote: > > On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: >> >> Being able to trigger BPF program on a different CPU could enable many >> use cases and optimizations. The use case I am looking at is to access >> perf_event and pe

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Andrii Nakryiko
On Wed, Aug 5, 2020 at 12:01 AM Song Liu wrote: > > > > > On Aug 4, 2020, at 10:47 PM, Andrii Nakryiko > > wrote: > > > > On Tue, Aug 4, 2020 at 9:47 PM Song Liu wrote: > >> > >> > >> > >>> On Aug 4, 2020, at 6:52 PM, Andrii Nakryiko > >>> wrote: > >>> > >>> On Tue, Aug 4, 2020 at 2:01 PM Son

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Andrii Nakryiko
On Wed, Aug 5, 2020 at 10:16 AM Alexei Starovoitov wrote: > > On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: > > > > Being able to trigger BPF program on a different CPU could enable many > > use cases and optimizations. The use case I am looking at is to access > > perf_event and percp

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Alexei Starovoitov
On Wed, Aug 05, 2020 at 04:47:30AM +, Song Liu wrote: > > Being able to trigger BPF program on a different CPU could enable many > use cases and optimizations. The use case I am looking at is to access > perf_event and percpu maps on the target CPU. For example: > 0. trigger the program

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-05 Thread Song Liu
> On Aug 4, 2020, at 10:47 PM, Andrii Nakryiko > wrote: > > On Tue, Aug 4, 2020 at 9:47 PM Song Liu wrote: >> >> >> >>> On Aug 4, 2020, at 6:52 PM, Andrii Nakryiko >>> wrote: >>> >>> On Tue, Aug 4, 2020 at 2:01 PM Song Liu wrote: > On Aug 2, 2020, at 10:10 PM, And

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-04 Thread Andrii Nakryiko
On Tue, Aug 4, 2020 at 9:47 PM Song Liu wrote: > > > > > On Aug 4, 2020, at 6:52 PM, Andrii Nakryiko > > wrote: > > > > On Tue, Aug 4, 2020 at 2:01 PM Song Liu wrote: > >> > >> > >> > >>> On Aug 2, 2020, at 10:10 PM, Andrii Nakryiko > >>> wrote: > >>> > >>> On Sun, Aug 2, 2020 at 9:47 PM Song

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-04 Thread Song Liu
> On Aug 4, 2020, at 6:52 PM, Andrii Nakryiko wrote: > > On Tue, Aug 4, 2020 at 2:01 PM Song Liu wrote: >> >> >> >>> On Aug 2, 2020, at 10:10 PM, Andrii Nakryiko >>> wrote: >>> >>> On Sun, Aug 2, 2020 at 9:47 PM Song Liu wrote: > On Aug 2, 2020, at 6:51 PM, Andrii Nakryi

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-04 Thread Andrii Nakryiko
On Tue, Aug 4, 2020 at 2:01 PM Song Liu wrote: > > > > > On Aug 2, 2020, at 10:10 PM, Andrii Nakryiko > > wrote: > > > > On Sun, Aug 2, 2020 at 9:47 PM Song Liu wrote: > >> > >> > >>> On Aug 2, 2020, at 6:51 PM, Andrii Nakryiko > >>> wrote: > >>> > >>> On Sat, Aug 1, 2020 at 1:50 AM Song Liu

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-04 Thread Song Liu
> On Aug 2, 2020, at 10:10 PM, Andrii Nakryiko > wrote: > > On Sun, Aug 2, 2020 at 9:47 PM Song Liu wrote: >> >> >>> On Aug 2, 2020, at 6:51 PM, Andrii Nakryiko >>> wrote: >>> >>> On Sat, Aug 1, 2020 at 1:50 AM Song Liu wrote: Add a benchmark to compare performance of 1)

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-02 Thread Andrii Nakryiko
On Sun, Aug 2, 2020 at 9:47 PM Song Liu wrote: > > > > On Aug 2, 2020, at 6:51 PM, Andrii Nakryiko > > wrote: > > > > On Sat, Aug 1, 2020 at 1:50 AM Song Liu wrote: > >> > >> Add a benchmark to compare performance of > >> 1) uprobe; > >> 2) user program w/o args; > >> 3) user program w/ args

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-02 Thread Song Liu
> On Aug 2, 2020, at 6:51 PM, Andrii Nakryiko wrote: > > On Sat, Aug 1, 2020 at 1:50 AM Song Liu wrote: >> >> Add a benchmark to compare performance of >> 1) uprobe; >> 2) user program w/o args; >> 3) user program w/ args; >> 4) user program w/ args on random cpu. >> > > Can you please

Re: [PATCH bpf-next 5/5] selftests/bpf: add benchmark for uprobe vs. user_prog

2020-08-02 Thread Andrii Nakryiko
On Sat, Aug 1, 2020 at 1:50 AM Song Liu wrote: > > Add a benchmark to compare performance of > 1) uprobe; > 2) user program w/o args; > 3) user program w/ args; > 4) user program w/ args on random cpu. > Can you please add it to the existing benchmark runner instead, e.g., along the other