• Jiri Olsa's avatar
    selftests/bpf: Add uprobe_multi usdt bench test · 85209e83
    Jiri Olsa authored
    Adding test that attaches 50k usdt probes in usdt_multi binary.
    
    After the attach is done we run the binary and make sure we get
    proper amount of hits.
    
    With current uprobes:
    
      # perf stat --null ./test_progs -n 254/6
      #254/6   uprobe_multi_test/bench_usdt:OK
      #254     uprobe_multi_test:OK
      Summary: 1/1 PASSED, 0 SKIPPED, 0 FAILED
    
       Performance counter stats for './test_progs -n 254/6':
    
          1353.659680562 seconds time elapsed
    
    With uprobe_multi link:
    
      # perf stat --null ./test_progs -n 254/6
      #254/6   uprobe_multi_test/bench_usdt:OK
      #254     uprobe_multi_test:OK
      Summary: 1/1 PASSED, 0 SKIPPED, 0 FAILED
    
       Performance counter stats for './test_progs -n 254/6':
    
             0.322046364 seconds time elapsed
    Signed-off-by: default avatarJiri Olsa <jolsa@kernel.org>
    Link: https://lore.kernel.org/r/20230809083440.3209381-26-jolsa@kernel.orgSigned-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
    85209e83
uprobe_multi_test.c 8.04 KB