Re: [PATCH bpf-next 3/5] selftests/bpf: factor out common helpers for benchmarks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 30, 2021 at 6:07 AM Hou Tao <houtao1@xxxxxxxxxx> wrote:
>
> Five helpers are factored out to reduce boilerplate for
> benchmark tests: do_getpgid(), getpgid_loop_producer(),
> assert_single_consumer(), assert_single_producer() and
> noop_consumer().
>
> Signed-off-by: Hou Tao <houtao1@xxxxxxxxxx>
> ---

Please drop this patch. All the stuff you are extracting into
"reusable" helpers is so trivial that it's not worth it. It just makes
it harder to follow each individual benchmark's setup.

>  tools/testing/selftests/bpf/bench.c           | 13 +++++
>  tools/testing/selftests/bpf/bench.h           | 25 +++++++++
>  .../bpf/benchs/bench_bloom_filter_map.c       | 44 ++++-----------
>  .../selftests/bpf/benchs/bench_count.c        | 14 +----
>  .../selftests/bpf/benchs/bench_rename.c       | 27 +++------
>  .../selftests/bpf/benchs/bench_ringbufs.c     |  7 +--
>  .../selftests/bpf/benchs/bench_trigger.c      | 55 +++++++------------
>  7 files changed, 81 insertions(+), 104 deletions(-)
>

[...]



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux