opt: add nonwritable-propagation pass #6844
All Vouch review confidence checks passed
Residual risk 0.15 = Change Risk (0.37) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 224 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.324
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #6844"
general
weight: 0.35
Wint3rNight
Fixes #6785.
DXC decorates every member of a buffer's struct
NonWritableinstead of decorating the variable. That's legal, but anything that reads the decoration off the variable doesn't see it, including the mapping APIs inVK_EXT_descriptor_heap, which is what breaks in the issue.--nonwritable-propagation: for each buffer variable (OpVariableorOpUntypedVariableKHR;StorageBuffer+Block,Uniform+BlockorUniform+BufferBlock; directly or through a descriptor array) whose struct has every member decoratedNonWritable, decorate the variableNonWritableand remove the now-redundant member decorations.NonWritableon a member covers everything reachable through it.The analysis is borrowed rather than rewritten:
IsVulkanStorageBuffer/IsVulkanUniformBufferdecide what is a buffer on the typed path, the untyped path checks storage class andBlock/BufferBlockitself, andDecorationManagerdoes the rest.GetPreservedAnalysesdrops onlykAnalysisDecorations.14 tests: SSBO, UBO,
BufferBlock, descriptor array, untyped variable with and without a data type, one writable member, a struct-typed member with and without the decoration, the DXCStructuredBuffer<S>shape, already-decorated (assertsSuccessWithoutChange), empty struct, non-buffer variable, andOffsetsurviving the member-decoration removal. Every output goes through the validator.