[webkit-reviews] review denied: [Bug 238710] [WebGPU] Implement Texture view format compatibility : [Attachment 456504] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Apr 3 23:08:26 PDT 2022


Myles C. Maxfield <mmaxfield at apple.com> has denied Myles C. Maxfield
<mmaxfield at apple.com>'s request for review:
Bug 238710: [WebGPU] Implement Texture view format compatibility
https://bugs.webkit.org/show_bug.cgi?id=238710

Attachment 456504: Patch

https://bugs.webkit.org/attachment.cgi?id=456504&action=review




--- Comment #4 from Myles C. Maxfield <mmaxfield at apple.com> ---
Comment on attachment 456504
  --> https://bugs.webkit.org/attachment.cgi?id=456504
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=456504&action=review

>> Source/WebGPU/WebGPU/Texture.mm:1119
>> +	    return std::nullopt;
> 
> There appears to be an inconsistency with the logic in this function. If
`WGPUTextureFormat_ASTC4x4Unorm` returns `WGPUTextureFormat_ASTC4x4Unorm`,
surely these should return themselves? What am I missing?

Yeah, I see what you mean.

Originally, this function was intended to create equivalence classes via
normalization; e.g. RGBA8Unorm and RGBA8UnormSrgb should both be members of the
same equivalence class, and this function returns a representative member of
that class (sort of like how union set works). ASTC4x4Unorm and
ASTC4x4UnormSrgb are in the same equivalence class. I was originally thinking
that formats like R8Unorm wouldn't be part of any equivalence class, so they
would return nullopt here, but I can also understand where you're coming from
about saying R8Unorm should be in an equivalence class of 1. I'll change the
implementation to do that.

>> Source/WebGPU/WebGPU/Texture.mm:1243
>> +	if (canonicalizedFormat1 != canonicalizedFormat1)
> 
> Comparison to self?!

����‍♂️


More information about the webkit-reviews mailing list