Re: [w3ctag/design-reviews] Incubation: CPU Performance API (Issue #1198)

nickie left a comment (w3ctag/design-reviews#1198)

In [PR #17](https://github.com/WICG/cpu-performance/pull/17) I have added a second example to the explainer. In this new example (copying from the PR):

> a web application may consider applying some effect that improves UX but requires excessive computation power. When it loads, it could use the CPU Performance API to determine **statically** if the user device is powerful enough to enable this effect. Afterwards, it could use the Compute Pressure API to **dynamically** monitor device usage, and control this effect accordingly. An interactive demo illustrates this use case.

The new example shows primarily how the two APIs complement each other. However, (again copying from the PR) it shows:
> also an important difference between the static information obtained by the CPU Performance API (the performance tier) and the dynamic information obtained by the Compute Pressure API (the pressure state). The former is **absolute**: it tells the web app how powerful the user device is, regardless of the current load or other conditions. The latter is **relative**: it tells the web app how well the user device is performing now, compared to what it would do in ideal conditions and with zero load. For the use case that is illustrated above, dynamic information alone is not sufficient to inform the web app whether the effect should be enabled. E.g., even if the pressure state is nominal, the user device may not be powerful enough to support it.

Special thanks to Alex Russel for suggesting this addition in [Chromium's I2S thread](https://groups.google.com/a/chromium.org/g/blink-dev/c/igPwzkxhQtk/m/Epzx3q7MBwAJ). I think that it makes it clear how each of the two APIs provides information that the other API cannot provide, and that is useful in a realistic scenario.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3ctag/design-reviews/issues/1198#issuecomment-4994865969
You are receiving this because you are subscribed to this thread.

Message ID: <w3ctag/design-reviews/issues/1198/4994865969@github.com>

Received on Thursday, 16 July 2026 17:40:37 UTC