RESOLVED FIXED 198706
[WHLSL] Remove unnecessary ASSERT()s and clean up visitor lambdas
https://bugs.webkit.org/show_bug.cgi?id=198706
Summary [WHLSL] Remove unnecessary ASSERT()s and clean up visitor lambdas
Myles C. Maxfield
Reported 2019-06-09 23:38:45 PDT
General cleanup. No behavior change.
Attachments
WIP (32.13 KB, patch)
2019-06-09 23:39 PDT, Myles C. Maxfield
no flags
Patch (35.55 KB, patch)
2019-06-12 23:54 PDT, Myles C. Maxfield
no flags
Patch (37.80 KB, patch)
2019-06-13 10:44 PDT, Myles C. Maxfield
dino: review+
Myles C. Maxfield
Comment 1 2019-06-09 23:39:15 PDT
Myles C. Maxfield
Comment 2 2019-06-09 23:40:13 PDT
*** Bug 198705 has been marked as a duplicate of this bug. ***
Jon Lee
Comment 3 2019-06-12 08:53:03 PDT
Changing to P1 since it blocks 198704.
Radar WebKit Bug Importer
Comment 4 2019-06-12 08:54:25 PDT
Myles C. Maxfield
Comment 5 2019-06-12 23:54:38 PDT
Myles C. Maxfield
Comment 6 2019-06-13 10:44:49 PDT
Saam Barati
Comment 7 2019-06-13 12:55:30 PDT
LGTM too.
Robin Morisset
Comment 8 2019-06-13 14:08:39 PDT
Comment on attachment 372066 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=372066&action=review r=me with just a nitpick. > Source/WebCore/Modules/webgpu/WHLSL/WHLSLIntrinsics.cpp:350 > + auto textureTypeIndex = std::find(m_textureTypeNames, m_textureTypeNames + WTF_ARRAY_LENGTH(m_textureTypeNames), nativeTypeDeclaration.name()) - m_textureTypeNames; I understand that is more concise, but I am not entirely comfortable with replacing some reasonable code by pointer arithmetic (the - m_textureTypeNames at the end). It gets me especially wary because of the auto. Is this std::ptrdiff_t ?uintptr_t ?
Myles C. Maxfield
Comment 9 2019-06-13 22:46:04 PDT
Note You need to log in before you can comment on or make changes to this bug.