← Back to Pull requests

[CPU][ARM] Fix INT8 FC weight-format probe and reject non-concrete ACL weight formats #38121

Closed
unknown closed this pull request without merging on Sep 17, 2026 17:42 UTC
View on GitHub
unknown unknown commented on Sep 14, 2026 09:47 UTC
Author

Details:


acl_fc_executor::prepareWeightMemory() asks ACL for the optimal weight layout via ACLWeightFormatGenerator (which calls NEFullyConnectedLayer::has_opt_impl(..., WeightFormat::ANY)) and, whenever that probe succeeds, repacks the FC weights into the reported arm_compute::WeightFormat using oneDNN's acl_utils::reorder_to_weight_format().

The problem is that a successful probe does not guarantee a concrete layout.
arm_gemm::has_opt_gemm() assigns the format from impl->do_instantiate(...)->get_config().weight_format, and GemmConfig::weight_format defaults to arm_compute::WeightFormat::ANY - so a kernel that simply does not need repacked weights reports ANY, and a gap in ACL's dispatch tables can leave the caller-seeded UNSPECIFIED in place while still returning Status{}.

Neither ANY nor UNSPECIFIED carries interleave/block counts, so arm_compute::interleave_by() and block_by() both return 0. Feeding either into reorder_to_weight_format() computes strides[I_dim] = interleave_by * block_by = 0, padded_dims[] = 0 and strides[O_dim] = 0, i.e. a zero-strided, zero-sized weights descriptor. The destination Memory then allocates 0 bytes,
getData() returns nullptr, and the following oneDNN reorder writes through a null pointer.

This is currently reachable: bumping the ComputeLibrary submodule from v53.1.0 to v53.3.0 makes CpuGemmAssemblyDispatch::has_opt_impl() return success without setting a weight format for an S8-destination lowp GEMM, and the CPU plugin SIGSEGVs inside compile_model() on BERT INT8 models.

ComputeLibrary PR: https://github.com/ARM-software/ComputeLibrary/pull/1314

The fix:


- ACLWeightFormatGenerator now probes with the types the executor actually configures.
- prepareWeightMemory() no longer trusts a non-concrete weight format

Diff: 232 lines (+174 / -58) across 2 files Reviewer: v-Golubev Review duration: 4794m
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 · 232 lines diff across 2 files
0.37
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
0.17
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
60%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
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.326
Shallow Review Depth shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #38121"
general weight: 0.35
Reviewers
Assignees
Unassigned
Labels
risk: low confidence: 60.5% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 37.1% (MEDIUM) · Higher = larger blast radius
37.1%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 60.5% · Lower = rushed or shallow review
60.5%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 14.6% · Safe to merge
14.6%