Re: [PATCH v1 0/2] Add procfs based memory and network tool events

From: Andi Kleen

Date: Mon Jan 12 2026 - 11:51:00 EST


Ian Rogers <irogers@xxxxxxxxxx> writes:

> Add events for memory use and network activity based on data readily
> available in /prod/pid/statm, /proc/pid/smaps_rollup and
> /proc/pid/net/dev. For example the network usage of chrome processes
> on a system may be gathered with:
> ```
> $ perf stat -e
> net_rx_bytes,net_rx_compressed,net_rx_drop,net_rx_errors,net_rx_fifo,net_rx_frame,net_rx_multicast,net_rx_packets,net_tx_bytes,net_tx_carrier,net_tx_colls,net_tx_compressed,net_tx_drop,net_tx_errors,net_tx_fifo,net_tx_packets
> -p $(pidof -d, chrome) -I 1000

But AFAIK that's for the complete network name space, not just the
process, thus highly misleading in perf context because the scope
is incompatible.

-Andi