File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7474 cargo install bpf-linker --git https://github.com/aya-rs/bpf-linker.git
7575 cargo +nightly build --verbose --target ${{ matrix.target }} --features stealth
7676 cargo +nightly build \
77- --release \
77+ --profile bpf \
7878 -p fault-ebpf-programs \
7979 --target=bpfel-unknown-none \
8080 -Z build-std=core
Original file line number Diff line number Diff line change @@ -322,7 +322,7 @@ jobs:
322322 cargo install bpf-linker --git https://github.com/aya-rs/bpf-linker.git
323323 cargo +nightly build --profile prod-fast --features stealth --target ${{ matrix.target }}
324324 cargo +nightly build \
325- --release \
325+ --profile bpf \
326326 -p fault-ebpf-programs \
327327 --target=bpfel-unknown-none \
328328 -Z build-std=core
@@ -334,7 +334,7 @@ jobs:
334334 cargo install bpf-linker --git https://github.com/aya-rs/bpf-linker.git
335335 cargo +nightly zigbuild --profile prod-fast --features stealth --target ${{ matrix.target }}
336336 cargo +nightly build \
337- --release \
337+ --profile bpf \
338338 -p fault-ebpf-programs \
339339 --target=bpfel-unknown-none \
340340 -Z build-std=core
Original file line number Diff line number Diff line change @@ -63,10 +63,13 @@ codegen-units = 1
6363# (leave out panic/lto/strip)
6464
6565# eBPF crate: conservative tweaks; again, no panic/lto/strip here
66- [profile .release .package .fault-ebpf-programs ]
67- opt-level = " z"
66+ [profile .bpf ]
67+ inherits = " release"
68+ lto = " off" # <<< IMPORTANT: no LTO for BPF
69+ opt-level = " z" # small is good for eBPF objects
6870codegen-units = 1
71+ panic = " abort"
6972debug = 0
7073debug-assertions = false
7174overflow-checks = false
72- # (leave out panic/lto/strip)
75+ strip = " debuginfo "
You can’t perform that action at this time.
0 commit comments