Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: ced1eafb18fd6397a9cf57777148df375a0e0331
https://github.com/WebKit/WebKit/commit/ced1eafb18fd6397a9cf57777148df375a0e0331
Author: David Kilzer <[email protected]>
Date: 2026-07-27 (Mon, 27 Jul 2026)
Changed paths:
M Source/WebGPU/WGSL/VisibilityValidator.cpp
Log Message:
-----------
[WGSL] Fix uninitialized VisibilityValidator::m_stage member
<https://bugs.webkit.org/show_bug.cgi?id=320319>
<rdar://183260812>
Reviewed by Dan Glastonbury.
The constructor initializes only `m_shaderModule`, leaving the
`m_stage` enum member with an indeterminate value. `validate()`
assigns `m_stage` per entry point before visiting each one, but a
shader module with no entry points never enters that loop, so any
later read of `m_stage` would observe an indeterminate value.
Initialize `m_stage` to `ShaderStage::Vertex`, matching how the
sibling `IOValidator` and `GlobalVariableRewriter` passes default the
same member. This silences the clang static analyzer's
`optin.cplusplus.UninitializedObject` finding.
* Source/WebGPU/WGSL/VisibilityValidator.cpp:
(WGSL::VisibilityValidator::VisibilityValidator):
Canonical link: https://commits.webkit.org/318025@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications