fix(dnn-providers): decline graphs engines cannot serve #15768
All Vouch review confidence checks passed
Residual risk 0.21 = Change Risk (0.52) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.52 · 650 lines diff across 8 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.388
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #15768"
general
weight: 0.35
BrianHarrisonAMD
Summary
Some provider engines accepted graphs they cannot serve, then returned wrong results, overran a buffer, or failed late at plan build or execute. Each engine now declines these graphs in
isApplicable, before plan build, and logs the cause. Three cases the first version declined are served: size-1 batch axes (hipBLASLt), a lower-rank per-channel conv bias (MIOpen) and a both-virtual batchnorm saved pair.This PR does not make the touched builders safe for every graph. Known problems that predate it are listed under "Not in this PR" and tracked in #16023, #16024, #16026-#16033 and ALMIOPEN-3313, 3016, 3309, 3310, 3331.
JIRA ID : ALMIOPEN-3259
Risk Assessment
Risk 3. Host-side applicability checks in three providers; no kernel or launch code changes. The main risk is declining a graph that is served today. Each decline follows the library's own checks where one exists, and the existing positive suites and the
standardintegration tier pass unchanged.When no plan builder applies, all four engines (ASM SDPA, MLOps, hipBLASLt, MIOpen) now throw
HIPDNN_PLUGIN_STATUS_INTERNAL_ERRORfrominitializeExecutionContext. Before, the plan-less context failed later, at the workspace query, with the same status. The backend still returnsHIPDNN_STATUS_PLUGIN_ERRORand the frontend still falls back to the next engine configuration (#14307). The ASM SDPA and MLOps workspace queries now throw too; hipBLASLt and MIOpen still return 0 (#16033). These paths are reached only whenisApplicableand the plan builders disagree.ASIC Coverage
| Target | Commit | Result |
|---|---|---|
| gfx942, gfx950 |
a51e9c37300| MIOpen and hipBLASLt unit binaries, HKP SDPA/MLOps/norm/resample subset, batchnorm integration tests, every new device-gated test: 0 failed || gfx942, gfx950 |
35bd383e301|standardintegration tier, all three provider lanes: passed || gfx1151 |
35bd383e301| HKP WMMA matchers, engine census, full unit binary: no new failures against the base || Windows gfx1151 |
a51e9c37300| hipBLASLt plugin API tests skip under #9962; unserved-graph test passes || gfx90a | - | HIP launch-limit probe behind the resample bound: 2^32 threads rejected, 2^32 - 256 accepted |
The later commits (resample bound
1b0ae442928, develop merges up to4bedf9be9a9) are host-tested.Testing Summary
b56540f2728c, 28 review-fix mutants ata51e9c37300, the resample bound at1b0ae442928). Device-only guards are covered by the device runs.HIPBLASLTPROVIDER_ENABLE_MX_GEMM=ON, which no CI lane sets; host-tested locally, no device run.Testing Checklist
4bedf9be9a9, no GPU: HKP 1006, hipBLASLt 224, MIOpen 1269 passed; 0 failed - Status: Passeda51e9c37300- Status: Passedstandardintegration tier at35bd383e301- Status: Passed35bd383e301; Windows gfx1151 hipBLASLt ata51e9c37300- Status: Passed4bedf9be9a9- Status: PendingTechnical Changes
Evidence: Device = reproduced on a GPU; Execute = accepted, then failed at plan build or execute; Earlier = declined at the base without a named cause; Defensive = not reachable through the backend, or not observed failing.
| Provider | Now declined | Evidence |
|---|---|---|
| hipBLASLt | Mixed A/B types; unsupported bias or activation-output type; pass-by-value tensors; wrong
virtualflags; non-packed bias; batch axes of extent above 1 that do not share one flattened stride, or a fused output with a different batch layout; MX (flag-gated): negative or non-dense scales | Device (bias, batch layout, MX); Execute (pass-by-value,virtual); Earlier (types) || MIOpen batchnorm | Partial running statistics or an unpaired saved pair; running statistics or a fused activation without the saved pair (a provider plan limit, #16028); a saved pair with one virtual; wrongly typed running statistics;
virtualor pass-by-value buffers; a ReLU lower clip without an upper clip (#16029) | Device (types, pass-by-value); Execute (saved pair,virtual, clip); Defensive (partial, unpaired) || MIOpen convolution | Pass-by-value tensors; a bias not per channel or of rank above the output's; a fused output that differs from MIOpen's output descriptor | Device (pass-by-value, bias); Execute (output) |
| MIOpen unary pointwise | Pass-by-value tensors; different input and output dims; any pair not both packed with one layout (workaround for #16024) | Device; Execute (baked value); Defensive (dims) |
| HKP MLOps batchnorm, LayerNorm, RMSNorm, resample | Partial running statistics;
virtualbuffers (fused RMSNorm checks x, y, inv_rms forward and dy, dx, dscale, dbias backward); element counts past the kernels' 32-bit limits (resample forward: a launch of 2^32 threads); an epsilon or momentum the graph cannot resolve | Device (statistics, counts); Execute (virtual); Defensive (epsilon, momentum) || HKP attention | ASM SDPA and Flash2: attributes the kernels ignore; ASM SDPA forward: inconsistent Q/K/V/O shapes. Unified and WMMA: unsupported compute types. FlyDSL RMSNorm: operands past 2^31-1 bytes (forward gamma, inv_rms; backward x, dy, dx, inv_rms). A
ragged_offset_multiplierwithout a ragged offset | Device (ASM SDPA and Flash2; shapes only through deserialize or the raw backend); Defensive (rest) |Served or unchanged:
[4,1,4,8]/[32,7,8,1]now gets batch offset 32; the base used the wrong offset 7.OperationSupport.mdpages list the new rules.Not in this PR (wrong at the base and at this head, reproduced on gfx950):
virtualoperands (#15148); Flash2 no-plan and ragged handling (engine off by default).