libxdp with bpf_stats_enabled question
"Brian G. Merrell" <[email protected]>
| Newsgroups | org.kernel.vger.xdp-newbies |
|---|---|
| Message-ID | <[email protected]> |
Hi,
I've been playing around with the new xdp-loader to chain xdp programs
with kernel.bpf_stats_enabled set. This is what I see (from bpftool
prog):
22: xdp name xdp_dispatcher tag d51e469e988d81da gpl run_time_ns 105086 run_cnt 24
loaded_at 2020-12-15T07:52:27+0000 uid 0
xlated 720B jited 535B memlock 4096B map_ids 5
btf_id 8
24: ext name xdp_pass tag 3b185187f1855c4c gpl
loaded_at 2020-12-15T07:52:27+0000 uid 0
xlated 16B jited 18B memlock 4096B
btf_id 9
26: ext name xdp_drop tag 57cd311f2e27366b gpl
loaded_at 2020-12-15T07:52:27+0000 uid 0
xlated 16B jited 18B memlock 4096B
btf_id 10
You'll notice that the run_time_ns and run_cnt stats are only populated
for the xdp_dispatcher. This is basically the same behavior we see today
with bpf_tail_call chaining, so it's not a regression or anything. It
would be really nice, though, if we could see those stats for each
individual xdp program in the chain. Does anyone know what it would take
for that to happen? Would it be more feasible for xdplib to optionally
report separate runtime stats itself for chained programs?
Thanks,
Brian