[webkit-changes] [WebKit/WebKit] a2a16a: [WGSL] Pointers should not be unpacked
Tadeu Zagallo
noreply at github.com
Fri May 10 09:58:02 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: a2a16a65166393cc268b7fbafb8f48082ac1984f
https://github.com/WebKit/WebKit/commit/a2a16a65166393cc268b7fbafb8f48082ac1984f
Author: Tadeu Zagallo <tzagallo at apple.com>
Date: 2024-05-10 (Fri, 10 May 2024)
Changed paths:
M Source/WebGPU/WGSL/GlobalVariableRewriter.cpp
A Source/WebGPU/WGSL/tests/valid/fuzz-127229681.wgsl
Log Message:
-----------
[WGSL] Pointers should not be unpacked
https://bugs.webkit.org/show_bug.cgi?id=273894
rdar://127229681
Reviewed by Mike Wyrzykowski.
The fuzzer found a crash due to the base of an index access being incorrectly
unpacked when it was an address-of expression. We would always unpack unary
expressions, since math operations should be performed on unpacked values, but
for pointer operators (address-of and dereference) we do not need to force the
operand to be unpacked.
* Source/WebGPU/WGSL/GlobalVariableRewriter.cpp:
(WGSL::RewriteGlobalVariables::visit):
(WGSL::RewriteGlobalVariables::getPacking):
* Source/WebGPU/WGSL/tests/valid/fuzz-127229681.wgsl: Added.
Canonical link: https://commits.webkit.org/278613@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list