qmonnet / rbpf

Rust virtual machine and JIT compiler for eBPF programs
Apache License 2.0
922 stars 235 forks source link

src/ebpf.rs: Increase instruction limit to 1 million #108

Closed seanyoung closed 5 months ago

seanyoung commented 5 months ago

The linux kernel allows programs of 1 million instructions, see

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c04c0d2b968ac45d6ef020316808ef6c82325a82

I'm hitting the 4096 limit in some corner cases with https://github.com/seanyoung/cir, if the infrared protocol is very complex (e.g. XMP). rbpf is used for testing the generated IR decoders in the test framework.