[webkit-changes] [WebKit/WebKit] f7fc51: [WebGPU] Loops are susceptible to UB optimizations
mwyrzykowski
noreply at github.com
Mon Dec 2 23:02:11 PST 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: f7fc51937f2ee3eb0258f99408985316f8b3e4d5
https://github.com/WebKit/WebKit/commit/f7fc51937f2ee3eb0258f99408985316f8b3e4d5
Author: Mike Wyrzykowski <mwyrzykowski at apple.com>
Date: 2024-12-02 (Mon, 02 Dec 2024)
Changed paths:
A LayoutTests/fast/webgpu/regression/repro_283595-for-expected.png
A LayoutTests/fast/webgpu/regression/repro_283595-for-expected.txt
A LayoutTests/fast/webgpu/regression/repro_283595-for.html
A LayoutTests/fast/webgpu/regression/repro_283595-loop-expected.png
A LayoutTests/fast/webgpu/regression/repro_283595-loop-expected.txt
A LayoutTests/fast/webgpu/regression/repro_283595-loop.html
A LayoutTests/fast/webgpu/regression/repro_283595-while-expected.png
A LayoutTests/fast/webgpu/regression/repro_283595-while-expected.txt
A LayoutTests/fast/webgpu/regression/repro_283595-while.html
M LayoutTests/platform/mac-wk2/TestExpectations
M Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp
Log Message:
-----------
[WebGPU] Loops are susceptible to UB optimizations
https://bugs.webkit.org/show_bug.cgi?id=283595
rdar://140334491
Reviewed by Dan Glastonbury.
Ensure loops always make forward progress otherwise UB can result
in the optimizer optimizing away necessary clamping functions.
* Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp:
(WGSL::Metal::FunctionDefinitionWriter::visit):
Emit volatile read to ensure forward progress.
* LayoutTests/fast/webgpu/regression/repro_283595-for-expected.png: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-for-expected.txt: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-for.html: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-loop-expected.png: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-loop-expected.txt: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-loop.html: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-while-expected.png: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-while-expected.txt: Added.
* LayoutTests/fast/webgpu/regression/repro_283595-while.html: Added.
Add regression test.
Canonical link: https://commits.webkit.org/287260@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