llvm-project
778c0fb1 - [SLP] Fix GEP cost computation for load vectorization cost estimates

Commit
23 days ago
[SLP] Fix GEP cost computation for load vectorization cost estimates Pass Instruction::Load instead of Instruction::GetElementPtr to getGEPCosts in isMaskedLoadCompress and CheckForShuffledLoads. These call sites estimate costs for wide contiguous loads and sub-vector load patterns, not for masked gather pointer vector formation. Using Instruction::GetElementPtr incorrectly triggered the gather-style cost path, which computes vector GEP formation costs. Since the call sites already add scalarization overhead for pointer vector building separately, this led to double-counting of pointer costs and inaccurate vectorization decisions. Reviewers: hiraditya, RKSimon Pull Request: https://github.com/llvm/llvm-project/pull/191620
Author
Parents
Loading