-
Notifications
You must be signed in to change notification settings - Fork 659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
btf: CO-RE relocation is very slow on bpf-next #1081
Comments
@lmb I think this is essentially the issue I was seeing awhile ago. |
Some digging into why there are these duplicate types: The types really are different as well:
We end up at
All of these fields either point at |
The only difference in
|
And this is out of the same vmlinux.h?
Could you follow the ids of run_array further to see where some of the properties differ? Was this with latest pahole? |
I'll do that. Not sure which pahole, the vmlinux is pulled from an
Here is the BTF blob: vmlinux-bpf-next-6.4.0-rc3-g60548b825b08.gz |
We end up at
|
A loop? 🤯 |
No, the script I had bailed out after the first diff, so it gave misleading results. I rewrote the thing in Go, now it gives me a real diff:
This says that
|
The problem is in ubuntu It doesn't just create duplicate BTF, it also creates really large types. For example, in ubuntu BTF there are 150983 types reachable from |
This should now be much better on |
Most notably to fix [1] which caused pwru's slow loading on Ubuntu. [1]: cilium/ebpf#1081 Signed-off-by: Martynas Pumputis <m@lambda.lt>
Most notably to fix [1] which caused pwru's slow loading on Ubuntu. [1]: cilium/ebpf#1081 Signed-off-by: Martynas Pumputis <m@lambda.lt>
Most notably to fix [1] which caused pwru's slow loading on Ubuntu. [1]: cilium/ebpf#1081 Signed-off-by: Martynas Pumputis <m@lambda.lt>
It doesn't seem to be part of any renovate PR. This also includes a fix for newer kernels: cilium/ebpf#1081 Signed-off-by: Anastasios Papagiannis <tasos.papagiannnis@gmail.com>
It doesn't seem to be part of any renovate PR. This also includes a fix for newer kernels: cilium/ebpf#1081 Signed-off-by: Anastasios Papagiannis <tasos.papagiannnis@gmail.com>
Using CO-RE to relocate against some common types like
struct net
,struct sk_buff
and so on takes a looong time.This was originally reported against pwru: cilium/pwru#189
The library spends a lot of time copying types to remove qualifiers:
The problem is exacerbated by the fact that some common types seem to be present a bunch of times in the kernel BTF:
Current CO-RE code will make a copy of every one of these types.
The text was updated successfully, but these errors were encountered: