github.com/dylandreimerink/gobpfld@v0.6.1-0.20220205171531-e79c330ad608/emulator/doc.go (about) 1 // package emulator contains a userspace emulator/runtime for eBPF. 2 // 3 // The primary use cases I can currently think of are: 4 // * Debugging, we can't debug eBPF programs when they run in the kernel, it would be nice if we have the option 5 // to start a debugger session for an eBPF program just like we do with dlv or gdb for userspace applications. 6 // * Dynamic program extension, ultimately eBPF was made as a sort of plugin language for the kernel, but it doesn't 7 // have to be limited to that. We could create a plugin system for go programs based on eBPF code, much like how 8 // some people use lua or javascript. 9 // 10 // eBPF was originally developed for use in Linux, but it doesn't have to be limited to that. In fact work is already 11 // underway to use eBPF in BSD's and Windows. There is noting inherently "Linux" about eBPF itself, all of the "Host" 12 // specific features are implemented via map types and helper functions. Therefor this emulator is architected in such 13 // a way that it can be used for both Linux-flavored eBPF programs as well as others inclusing custom map and helper 14 // function types dedicated for other applications. 15 package emulator