RESOLVED FIXED 199740
[WebGPU] Move error scopes out of GPUDevice for more portable error generation
https://bugs.webkit.org/show_bug.cgi?id=199740
Summary [WebGPU] Move error scopes out of GPUDevice for more portable error generation
Justin Fan
Reported 2019-07-11 17:39:49 PDT
[WebGPU] Move error scopes out of GPUDevice for more portable error generation
Attachments
Patch (29.16 KB, patch)
2019-07-11 17:54 PDT, Justin Fan
no flags
Patch (30.64 KB, patch)
2019-07-12 13:21 PDT, Justin Fan
no flags
Justin Fan
Comment 1 2019-07-11 17:54:00 PDT
Myles C. Maxfield
Comment 2 2019-07-11 18:05:17 PDT
Comment on attachment 373984 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=373984&action=review > Source/WebCore/Modules/webgpu/WebGPUDevice.cpp:90 > + auto buffer = m_device->tryCreateBuffer(descriptor, false, m_errorGenerator.copyRef()); It's not obvious what "false" means here. Usually we use two-value enums to make this more readable. > Source/WebCore/Modules/webgpu/WebGPUDevice.cpp:189 > -void WebGPUDevice::pushErrorScope(GPUErrorFilter filter) const > +void WebGPUDevice::popErrorScope(ErrorPromise&& promise) wat > Source/WebCore/platform/graphics/gpu/cocoa/GPUBufferMetal.mm:105 > + errorGenerator->generateError("", GPUErrorFilter::OutOfMemory); "generator" isn't really the best name. It doesn't actually generate errors...
Justin Fan
Comment 3 2019-07-11 18:15:22 PDT
Comment on attachment 373984 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=373984&action=review >> Source/WebCore/Modules/webgpu/WebGPUDevice.cpp:189 >> +void WebGPUDevice::popErrorScope(ErrorPromise&& promise) > > wat Moved implementation of pushErrorScope to header since it's trivial and we need to include GPUErrorGenerator anyway.
Justin Fan
Comment 4 2019-07-12 13:21:08 PDT
Justin Fan
Comment 5 2019-07-12 14:07:55 PDT
Comment on attachment 374030 [details] Patch Clearing flags on attachment: 374030 Committed r247397: <https://trac.webkit.org/changeset/247397>
Justin Fan
Comment 6 2019-07-12 14:07:56 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 7 2019-07-12 14:08:13 PDT
Ryan Haddad
Comment 8 2019-07-15 13:38:09 PDT
Rolled out in https://trac.webkit.org/r247442 because it conflicted with the rollout of https://bugs.webkit.org/show_bug.cgi?id=199655, which broke the watchOS build.
Ryan Haddad
Comment 9 2019-07-15 13:38:21 PDT
Reopening.
Justin Fan
Comment 10 2019-07-16 17:04:18 PDT
Note You need to log in before you can comment on or make changes to this bug.