mirror of
https://github.com/xdp-project/xdp-tools.git
synced 2026-07-27 06:24:09 +00:00
Utilities and example programs for use with XDP
- C 79.6%
- Roff 11.1%
- Shell 6.1%
- Makefile 1.8%
- Python 1.1%
- Other 0.2%
When the tracepoint is active for xdp_devmap_xmit, we will constantly hammer bucket spin lock even when the entry already exists. This scales poorly with multiple threads generating traffic. Defer update to create the entry to first lookup failure, so that contention can be avoided. Before this change, up to 30% of time on CPUs would be spent in the slow path, and after this the contention drops to 0. In a test scenario xmit/s went from 15 million to 20 million with 16 threads. Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com> |
||
|---|---|---|
| .github | ||
| headers | ||
| lib | ||
| LICENSES | ||
| packaging | ||
| xdp-bench | ||
| xdp-dump | ||
| xdp-filter | ||
| xdp-forward | ||
| xdp-loader | ||
| xdp-monitor | ||
| xdp-trafficgen | ||
| .clang-format | ||
| .dockerignore | ||
| .gitignore | ||
| .gitmodules | ||
| .lgtm.yml | ||
| configure | ||
| LICENSE | ||
| Makefile | ||
| mkarchive.sh | ||
| README.org | ||
| version.mk | ||
xdp-tools - Library and utilities for use with XDP
This repository contains the libxdp library for working with the eXpress Data
Path facility of the Linux kernel, and a collection of utilities and example
code that uses the library.
The repository contains the following:
- lib/libxdp/ - the
libxdplibrary itself - can be built standalone usingmake libxdp - xdp-bench/ - an XDP benchmarking tool
- xdp-dump/ - a tcpdump-like tool for capturing packets at the XDP layer
- xdp-filter/ - a simple packet filtering utility powered by XDP
- xdp-forward/ - an XDP forwarding plane
- xdp-loader/ - a command-line utility for loading XDP programs using
libxdp - xdp-monitor/ - a simple XDP tracepoint monitoring tool
- xdp-trafficgen/ - an XDP-based packet generator
- headers/xdp/ - reusable eBPF code snippets for XDP (installed in /usr/include/xdp by
make install). - lib/util/ - common code shared between the different utilities
- packaging/ - files used for distro packaging
- lib/libbpf/ - a git submodule with libbpf, used if the system version is not recent enough
To compile, first run ./configure, then simply type make. Make sure you
either have a sufficiently recent libbpf installed on your system, or that you
pulled down the libbpf git submodule (git submodule init && git submodule
update).
For a general introduction to XDP, please see the XDP tutorial, and for more BPF and XDP examples, see the bpf-examples repository.