Skip to content

Conversation

@kernel-patches-daemon-bpf-rc
Copy link

Pull request for series with
subject: fprobe: use rhashtable for fprobe_ip_table
version: 3
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: e8d780d
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: 821c9e5
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: a6923c0
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

For now, all the kernel functions who are hooked by the fprobe will be
added to the hash table "fprobe_ip_table". The key of it is the function
address, and the value of it is "struct fprobe_hlist_node".

The budget of the hash table is FPROBE_IP_TABLE_SIZE, which is 256. And
this means the overhead of the hash table lookup will grow linearly if
the count of the functions in the fprobe more than 256. When we try to
hook all the kernel functions, the overhead will be huge.

Therefore, replace the hash table with rhltable to reduce the overhead.

Signed-off-by: Menglong Dong <[email protected]>
We need to get all the kernel function that can be traced sometimes, so we
move the get_syms() and get_addrs() in kprobe_multi_test.c to
trace_helpers.c and rename it to bpf_get_ksyms() and bpf_get_addrs().

Signed-off-by: Menglong Dong <[email protected]>
Some functions is recursive for the kprobe_multi and impact the benchmark
results. So just skip them.

Signed-off-by: Menglong Dong <[email protected]>
For now, the benchmark for kprobe-multi is single, which means there is
only 1 function is hooked during testing. Add the testing
"kprobe-multi-all", which will hook all the kernel functions during
the benchmark. And the "kretprobe-multi-all" is added too.

Signed-off-by: Menglong Dong <[email protected]>
@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

9 similar comments
@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

27 similar comments
@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@kernel-patches-daemon-bpf-rc
Copy link
Author

Upstream branch: f3af62b
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=987294
version: 3

@theihor theihor closed this Aug 5, 2025
@kernel-patches-daemon-bpf-rc kernel-patches-daemon-bpf-rc bot deleted the series/986284=>bpf-next branch August 7, 2025 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants