w3c / compute-pressure

A web API proposal that provides information about available compute capacity
https://www.w3.org/TR/compute-pressure/
Other
69 stars 10 forks source link

Use-case: Current process contribution #8

Open alexcyn opened 3 years ago

alexcyn commented 3 years ago

It would be very helpful to know current browser process (tab) contribution into the total CPU load. For example, I have a powerful machine, I am in the video conference, and also I run chromium build. CPU becomes 100% busy, but it does not make sense to reduce number of video feeds in the conference, as this will not save any visible CPU amount - most CPU is taken by build process. In the video conference code I would analyze current process contribution, and if it is less than lets say 50%, I would avoid any CPU saving activities.

kenchris commented 2 years ago

We have gotten this exact request a few times now from people in the web community and other stakeholders.

CPU stall pressure is currently representing global pressure, which covers many of the initial use-cases, but developers have expressed interest in getting the stall pressure for certain processes of interest, which allows the ability to understand performance impact of changes and doing A/B testing in the wild.

The interesting processes are the following:

Additionally, if the use is decoding using WebCodec on a thread, we might need combined measurements for hardware decoder and thread

arskama commented 5 months ago

We have started to evaluate a possible implementation on Chromium, this work will continue in Q2.