Closed Bug 2094980 Opened 12 days ago Closed 9 days ago

[wpt-sync] Sync PR 65044 - WebKit export of https://bugs.webkit.org/show_bug.cgi?id=330046

Categories

(Core :: WebVR, task, P4)

task

Tracking

()

RESOLVED FIXED
163 Branch
Tracking Status
firefox163 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 65044 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/65044
Details from upstream follow.

Mike Wyrzykowski <mwyrzykowski@apple.com> wrote:

WebKit export of https://bugs.webkit.org/show_bug.cgi?id=330046

WebKit export from bug: WebGPU layer followup for 328936

<pre>
[WebXR] Destroying a layer does not release its graphics resources

XRCompositionLayer.destroy() drops the texture wrappers it handed out, but the graphics memory behind
the layer stays alive until the layer object itself goes away, which can be much later when the page
still references it.

For WebGL, the swapchains only released their GL textures and images in their destructors. Their cleanup
moves into a new WebXRWebGLSwapchain::releaseResources(), which the backing now calls from the new
XRLayerBacking::releaseResources() when the layer is destroyed.

For WebGPU, the GPU process kept the compositor textures imported for the layer, its completion event and
its rasterization rate maps, and the device's XR subimage kept wrappers around the same textures. A new
WebGPU::XRProjectionLayer::destroy() is sent to the GPU process as RemoteXRProjectionLayer::Destroy and
drops all of them. The textures are released, not destroyed, because on Cocoa every WebXR layer shares
the compositor's drawable.

XRGPUBinding also now rejects destroyed layers with an InvalidStateError, like XRWebGLBinding does.

WebKit-Bug: <a href="https://bugs.webkit.org/show_bug.cgi?id=330046">https://bugs.webkit.org/show_bug.cgi?id=330046</a>
WebKit-Canonical-Link: <a href="https://commits.webkit.org/325824@main">https://commits.webkit.org/325824@main</a>
</pre>

Component: web-platform-tests → WebVR
Product: Testing → Core

CI Results

Ran 3 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 23 tests

Status Summary

Firefox

OK : 1
FAIL: 3

Chrome

OK : 1
FAIL: 3

Safari

OK : 1
FAIL: 3

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Tests Disabled in Gecko Infrastructure

Status: NEW → RESOLVED
Closed: 9 days ago
Resolution: --- → FIXED
Target Milestone: --- → 163 Branch
You need to log in before you can comment on or make changes to this bug.