[dpdk-dev] [PATCH 0/5] add apistats function
yamashita.hideyuki at ntt-tx.co.jp
Tue Dec 22 03:22:57 CET 2020
Thanks for your comments.
Please see my comments inline tagged with [HY].
> 04/12/2020 08:51, Hideyuki Yamashita:
> > In general, DPDK application consumes CPU usage because it polls
> > incoming packets using rx_burst API in infinite loop.
> > This makes difficult to estimate how much CPU usage is really
> > used to send/receive packets by the DPDK application.
> > For example, even if no incoming packets arriving, CPU usage
> > looks nearly 100% when observed by top command.
> > It is beneficial if developers can observe real CPU usage of the
> > DPDK application.
> > Such information can be exported to monitoring application like
> > prometheus/graphana and shows CPU usage graphically.
> > To achieve above, this patch set provides apistats functionality.
> > apistats provides the followiing two counters for each lcore.
> > - rx_burst_counts[RTE_MAX_LCORE]
> > - tx_burst_counts[RTE_MAX_LCORE]
> > Those accumulates rx_burst/tx_burst counts since the application starts.
> Please could you compare with what rte_jobstats offers?
> I feel all of this shares the same goals as librte_power work.
Thanks for your commetns.
You are correct. As you well know, l3fwd-power measures "how cpu cores
And in that sense, the goal of my proposal is the same with yours .
Moreover l3fwd-power is more precise than my proposal.
Point of my proposal is
- more easy to use
- less code impact on application code
I think that if application developer wants to need to measure "how cpu
cores are busy" he/she will needs to implement
- logic similar with l3fwd-power
- use jobstats API
But it is rather heavy for existing applications.
By using my proposal, it is "much easier" to implement.
(But it is "rough" measurement. I think it is trade-off)
How do you think about the idea?
> > - basic API counting functionality(apistats) into librte_ethdev
> Could it be it be accessible via rte_telemetry?
Currently, no reason not using telemetry.
I think telemetry is useful for applications which does NOT call DPDK
API(C lang API) directly.
My patchset provide only C API to retrieve apistats.
But if assuming not all applications call C API, then I think it is
reasonable to add telemetry in addition to C API for exposing stats.
Do you think "exposure via C API" is not needed?
More information about the dev