Is the requirement for cross-origin isolation stricter than the
requirements to use EXT_disjoint_timer_query{_webgl2}? If so it will
present a porting problem when switching WebGL content to WebGPU.


On Thu, 26 Oct 2023 at 11:21, 'François Beaufort' via blink-dev <
[email protected]> wrote:

>
>
> On Thu, Oct 26, 2023 at 11:05 AM Domenic Denicola <[email protected]>
> wrote:
>
>>
>>
>> On Thu, Oct 26, 2023 at 5:21 PM 'François Beaufort' via blink-dev <
>> [email protected]> wrote:
>>
>>> Contact emails
>>>
>>> [email protected], [email protected]
>>>
>>> Explainer
>>>
>>> https://github.com/gpuweb/gpuweb/issues/614
>>>
>>> Specification
>>>
>>> https://gpuweb.github.io/gpuweb/#timestamp
>>>
>>> Summary
>>>
>>> WebGPU timestamp queries allow WebGPU applications to measure precisely
>>> (down to the nanosecond) how much time their GPU commands take to execute,
>>> especially at the beginning and end of passes. Timestamp queries are
>>> heavily used to gain insights into the performance and behavior of GPU
>>> workloads.
>>>
>>> While the WebGPU specification makes timestamp queries an optional
>>> feature due to timing attack concerns, we believe that timestamp queries
>>> quantization provides a good middle ground by reducing the precision of
>>> timers. To offer even more advanced protection against timing attacks and
>>> fingerprinting, timestamp queries are also coarsened based on site
>>> isolation status:
>>>
>>> - Isolated contexts: timestamp queries are exposed with a resolution of
>>> 100 microseconds.
>>>
>>> - Non-isolated contexts: timestamp queries are not exposed at all.
>>>
>>
>> By "isolated" do you mean "has the cross-origin isolated capability
>> <https://html.spec.whatwg.org/#concept-settings-object-cross-origin-isolated-capability>
>> "?
>>
>
> Yes.
>
>
>>
>> I wasn't able to find any spec or tests for this requirement, which seems
>> like a potential interoperability issue.
>>
>
> The WebGPU spec currently says: "The feature is optional, and a WebGPU
> implementation may limit its exposure only to those scenarios that are
> trusted."
> See
> https://gpuweb.github.io/gpuweb/#security-timing:~:text=The%20feature%20is%20optional%2C%20and%20a%20WebGPU%20implementation%20may%20limit%20its%20exposure%20only%20to%20those%20scenarios%20that%20are%20trusted
>
>
>>
>>
>>>
>>> Blink component
>>>
>>> Blink>WebGPU
>>> <https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3EWebGPU>
>>>
>>> TAG review
>>>
>>> WebGPU spec: https://github.com/w3ctag/design-reviews/issues/626
>>>
>>> TAG review status
>>>
>>> A new TAG review was not requested because timestamp queries were
>>> already part of the original one for the WebGPU spec and was approved.
>>>
>>> Risks
>>>
>>> Interoperability and Compatibility
>>>
>>> Timestamp queries have not yet been implemented in any browser, but have
>>> been approved by the GPU for the Web Community Group, with representatives
>>> from Chrome, Firefox, and Safari. See
>>> https://github.com/gpuweb/gpuweb/wiki/Minutes-2021-09-27#:~:text=consensus%20to%20support%20end/begin%2Dpass%20timestamp%20queries
>>>
>>> Gecko: Positive (https://bugzilla.mozilla.org/show_bug.cgi?id=1827998)
>>>
>>> WebKit: Positive (https://github.com/gpuweb/gpuweb/pull/2190)
>>>
>>> Web developers: Positive. It’s one of the most common requested
>>> features. Many developers already use it today by running chrome with a
>>> special flag. See
>>> https://omar-shehata.medium.com/how-to-use-webgpu-timestamp-query-9bf81fb5344a
>>> Note that it was heavily used to benchmark and optimize Tensorflow.js.
>>>
>>> Other signals:
>>>
>>> WebView application risks
>>>
>>> Does this intent deprecate or change behavior of existing APIs, such
>>> that it has potentially high risk for Android WebView-based applications?
>>>
>>> None at the moment, WebGPU currently does not ship on Android WebView.
>>> Parallel work is occurring to launch WebGPU on Android.
>>>
>>>
>>> Debuggability
>>>
>>> No DevTools changes are required.
>>>
>>> Will this feature be supported on all six Blink platforms (Windows, Mac,
>>> Linux, Chrome OS, Android, and Android WebView)?
>>>
>>> No
>>>
>>> All platforms will eventually have support. Will immediately be
>>> available on ChromeOS, Mac, and Windows, since those platforms already
>>> support WebGPU. Linux and Android are planned to have WebGPU support in the
>>> future, so this feature will become available when WebGPU does.
>>>
>>> Is this feature fully tested by web-platform-tests
>>> <https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_platform_tests.md>
>>> ?
>>>
>>> Yes
>>>
>>> WebGPU/WGSL have a conformance test suite (https://github.com/gpuweb/cts)
>>> that is regularly pulled into Chromium and part of the testing of Dawn/Tint
>>> in Chromium.
>>>
>>> Flag name on chrome://flags
>>>
>>> None
>>>
>>> Finch feature name
>>>
>>> None
>>>
>>> Non-finch justification
>>>
>>> None
>>>
>>> Requires code in //chrome?
>>>
>>> False
>>>
>>> Tracking bug
>>>
>>> https://bugs.chromium.org/p/dawn/issues/detail?id=1800
>>>
>>> Availability expectation
>>>
>>> Feature is available only in Chromium browsers for the near future, on
>>> the order of months. Other browsers intend to ship WebGPU support, but
>>> don't have specified timelines.
>>>
>>> Non-OSS dependencies
>>>
>>> Does the feature depend on any code or APIs outside the Chromium open
>>> source repository and its open-source dependencies to function?
>>>
>>> No
>>>
>>> Estimated milestones
>>>
>>> Shipping on desktop
>>>
>>> 121
>>>
>>> Anticipated spec changes
>>>
>>> Open questions about a feature may be a source of future web compat or
>>> interop issues. Please list open issues (e.g. links to known github issues
>>> in the project for the feature specification) whose resolution may
>>> introduce web compat/interop risk (e.g., changing to naming or structure of
>>> the API in a non-backward-compatible way).
>>>
>>> None
>>>
>>> Link to entry on the Chrome Platform Status
>>>
>>> https://chromestatus.com/feature/5136606877188096
>>>
>>> This intent message was generated by Chrome Platform Status
>>> <https://chromestatus.com/>.
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "blink-dev" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to [email protected].
>>> To view this discussion on the web visit
>>> https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPpwU5%2BEFoeuehbvaMwzXK3wZ6UxX0U4n7yZJwwJgVOADbBwHA%40mail.gmail.com
>>> <https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPpwU5%2BEFoeuehbvaMwzXK3wZ6UxX0U4n7yZJwwJgVOADbBwHA%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "blink-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPpwU5%2B2kO0iA3TKMz5WbYAk42ZRv_1JJz8RvhzpAnLvKy6MQA%40mail.gmail.com
> <https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPpwU5%2B2kO0iA3TKMz5WbYAk42ZRv_1JJz8RvhzpAnLvKy6MQA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAABs73hS4pSQTgw65s_aiPWokAe9GR%3DFk3XFz_a-D3pkdj_peA%40mail.gmail.com.

Reply via email to