Provide a CLI option --btf which provides an experimental BTF support.
This includes a sanitization logic, which modifies the debug info in order to make it acceptable by the kernel, which includes:
A requirement for names to be compatible with C.
Removing DI for data-carrying enums.
Removing name from types annotated with AyaBtfMapMarker - Linux kernel requires maps to be anonymous structures, but Rust doesn't support anonymous types. This is our way to make it working.
Sorting type members by offsets (sometimes they arrive out of order).
Setting linkage of all functions which are not BPF programs to static.
Provide a CLI option
--btf
which provides an experimental BTF support.This includes a sanitization logic, which modifies the debug info in order to make it acceptable by the kernel, which includes:
AyaBtfMapMarker
- Linux kernel requires maps to be anonymous structures, but Rust doesn't support anonymous types. This is our way to make it working.static
.Updates: #1 Closes: #177 #26