Re: [RFC PATCH 2/4] eal: allow applications to report their cpu utilization

2022-11-23 Thread Stephen Hemminger
On Wed, 23 Nov 2022 11:19:29 +0100 Robin Jarry wrote: > +static rte_lcore_busy_percent_cb lcore_busy_cb; > +static unsigned int lcore_busy_period; > + > +void > +rte_lcore_register_busy_percent_cb(rte_lcore_busy_percent_cb cb, unsigned > int period) > +{ > + lcore_busy_cb = cb; > + lcore

Re: [RFC PATCH 2/4] eal: allow applications to report their cpu utilization

2022-11-23 Thread Robin Jarry
Hi Morten, Morten Brørup, Nov 23, 2022 at 12:52: > This patch is based on a "gauge" (i.e. the busyness percentage) and an > "interval" (i.e. the duration the gauge covers). I have to sample this > gauge exactly every interval to collect data for a busyness chart. If > the application's reporting i

RE: [RFC PATCH 2/4] eal: allow applications to report their cpu utilization

2022-11-23 Thread Morten Brørup
> From: Robin Jarry [mailto:rja...@redhat.com] > Sent: Wednesday, 23 November 2022 11.19 > To: dev@dpdk.org > Cc: Bruce Richardson; Jerin Jacob; Kevin Laatz; Konstantin Ananyev; > Mattias Rönnblom; Morten Brørup; Robin Jarry > Subject: [RFC PATCH 2/4] eal: allow applications t

[RFC PATCH 2/4] eal: allow applications to report their cpu utilization

2022-11-23 Thread Robin Jarry
Allow applications to register a callback that will be invoked in rte_lcore_dump() and when requesting lcore info in the telemetry API. The callback is expected to return a number between 0 and 100 representing the percentage of busy cycles spent over a fixed period of time. The period of time is

[RFC PATCH 2/4] eal: allow applications to report their cpu utilization

2022-11-23 Thread Robin Jarry
Allow applications to register a callback that will be invoked in rte_lcore_dump() and when requesting lcore info in the telemetry API. The callback is expected to return a number between 0 and 100 representing the percentage of busy cycles spent over a fixed period of time. The period of time is