Jesper Dangaard Brouer 7af928b8a8 lib_xsk_extend: Expose more direct xsk_btf_member API
With the current xsk_btf__read() we are seeing a slowdown on the
first packet with timestamps.  The theory is this is caused
by the allocation for the cached hashmap entry.

meta-time rx_ktime:870394156129518 time_now:870394156139039 diff:9521 ns
meta-time rx_ktime:870396208293894 time_now:870396208295098 diff:1204 ns
meta-time rx_ktime:870398256286553 time_now:870398256287772 diff:1219 ns

Create a new API that can access struct members more directly
via caching the xsk_btf_member offset + size in the C-code API user.

Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
2021-11-04 10:25:16 +01:00
2021-06-21 22:51:57 +02:00
2021-10-05 00:44:43 +02:00

Practical BPF examples

This git repository contains a diverse set of practical BPF examples that solve (or demonstrate) a specific use-case using BPF.

It is meant to ease doing rapid prototyping and development, writing C-code BPF programs using libbpf. The goal is to make is easier for developers to get started coding.

Many developers struggle to get a working BPF build environment. The repo enviroment makes it easy to build/compile BPF programs by doing the necessary libbpf setup transparently and detect missing compile dependencies (via the (configure)[configure] script). It is a declared goal to make BPF programming more consumable by detecting and reporting issues (when possible).

Description
No description provided
Readme 25 MiB
Languages
C 93.6%
Shell 4.7%
Makefile 1.6%