[CPU][ARM] Fix INT8 FC weight-format probe and reject non-concrete ACL weight formats #38121
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
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.326
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #38121"
general
weight: 0.35
v-Golubev
Details:
acl_fc_executor::prepareWeightMemory()asks ACL for the optimal weight layout viaACLWeightFormatGenerator(which callsNEFullyConnectedLayer::has_opt_impl(..., WeightFormat::ANY)) and, whenever that probe succeeds, repacks the FC weights into the reportedarm_compute::WeightFormatusing oneDNN'sacl_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 fromimpl->do_instantiate(...)->get_config().weight_format, andGemmConfig::weight_formatdefaults toarm_compute::WeightFormat::ANY- so a kernel that simply does not need repacked weights reportsANY, and a gap in ACL's dispatch tables can leave the caller-seededUNSPECIFIEDin place while still returningStatus{}.Neither
ANYnorUNSPECIFIEDcarries interleave/block counts, soarm_compute::interleave_by()andblock_by()both return0. Feeding either intoreorder_to_weight_format()computesstrides[I_dim] = interleave_by * block_by = 0,padded_dims[] = 0andstrides[O_dim] = 0, i.e. a zero-strided, zero-sized weights descriptor. The destinationMemorythen allocates 0 bytes,getData()returnsnullptr, 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 anS8-destination lowp GEMM, and the CPU plugin SIGSEGVs insidecompile_model()on BERT INT8 models.ComputeLibrary PR: https://github.com/ARM-software/ComputeLibrary/pull/1314
The fix:
-
ACLWeightFormatGeneratornow probes with the types the executor actually configures.-
prepareWeightMemory()no longer trusts a non-concrete weight format