Closed Bug 1860958 Opened 7 months ago Closed 6 months ago

Handle wgpu::Texture::Destroy() correctly

Categories

(Core :: Graphics: WebGPU, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
122 Branch
Tracking Status
firefox122 --- fixed

People

(Reporter: sotaro, Assigned: nical)

References

Details

Crash Data

Attachments

(1 file)

Texture::Destroy() is implemented as part of Bug 1856787. But it causes the regression Bug 1860921. Texture::Destroy() should be handled correctly

Depends on: 1860921
Depends on: 1860920
Blocks: 1843891
Flags: needinfo?(nical.bugzilla)
Flags: needinfo?(jimb)

I suspect that if we run into these crashes it is because Texture::Destroy ended up calling texture_drop on the wgpu side. All of the _drop functions in wgpu are only meant to be used when the last reference to the texture is gone. Generally there are _destroy methods which do some deinitialization but keep the texture registered with a flag marking it as invalid.

Flags: needinfo?(nical.bugzilla)

Yeah so I had a look and the situation was as I descried. I'll implement it since I am familiar with it.

Assignee: nobody → nical.bugzilla
Flags: needinfo?(jimb)
Pushed by nsilva@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5e6f2b2e19c6
Implement Texture::Destroy. r=webgpu-reviewers,jimb

Backed out for causing build bustages in RefPtr.h

  • Backout link
  • Push with failures
  • Failure Log
  • Failure line: /builds/worker/workspace/obj-build/dist/include/mozilla/RefPtr.h:54:38: error: member access into incomplete type 'mozilla::webgpu::CommandEncoder'
Flags: needinfo?(nical.bugzilla)
Pushed by nsilva@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d676e8a3a515
Implement Texture::Destroy. r=webgpu-reviewers,jimb
Pushed by nsilva@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/2b8905730799
Implement Texture::Destroy. r=webgpu-reviewers,jimb
Status: NEW → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 122 Branch
Flags: needinfo?(nical.bugzilla)
Blocks: 1864492
Duplicate of this bug: 1864492

Copying crash signatures from duplicate bugs.

Crash Signature: [@ wgpu_core::storage::Storage<T>::get_mut<T>]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: