I've been doing some benchmarking with AF_XDP, and more specific the bpf_xdp_redirect_map() helper and xdp_do_redirect(). One thing that puzzles me is that the percpu-variable accesses stands out. I did a horrible hack that just accesses a regular global variable, instead of the percpu struct bpf_redirect_info, and got a performance boost from 22.7 Mpps to 23.8 Mpps with the rxdrop scenario from xdpsock. Have anyone else seen this? So, my question to the uarch/percpu folks out there: Why are percpu accesses (%gs segment register) more expensive than regular global variables in this scenario. One way around that is changing BPF_PROG_RUN, and BPF_CALL_x to pass a context (struct bpf_redirect_info) explicitly, and access that instead of doing percpu access. That would be a pretty churny patch, and before doing that it would be nice to understand why percpu stands out performance-wise. Cheers, Björn