aya
aya copied to clipboard
[Proposal] Add --prune-unused option to aya-gen
I don't know how easy/hard this would be, but it would be cool if aya-gen had a --prune-unused flag that would remove unused struct fields and any types they depend on from the generated bindings. The use case for this would be generating an extremely minified vmlinux.rs file for use with BTF programs.
This would probably need to hold off until we add BTF support to aya-bpf.