Landing: 3adb33259541

Project / Subsystem

gcc / gcc/tree-optimization

Date

2026-07-15

Author

Richard Biener

Commit

3adb3325954177939d59031055fc08a81ae21be3

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
gcc/tree-optimization
patch_id
commit_hash
3adb3325954177939d59031055fc08a81ae21be3
source_type
github
headline
Improve BB vectorization of reductions
tldr
Enhances loop vectorization for reductions by improving SLP discovery and handling of non-uniform operation chains.
author
Richard Biener
outcome
committed
performance_win
true
breaking_change
false
series_id
series_parts
[]
tags
  • gcc
  • optimization
  • vectorization
discussion_id_link
bugzilla_pr
date
2026-07-15T00:00:00.000Z

This commit improves the vectorization of reduction operations in basic blocks (BBs) by refining the use of Super Low-Power (SLP) vectorization. Previously, uneven operation chains led to premature stripping of operations to achieve an even number of lanes, which was suboptimal. The change removes this early stripping, allowing SLP to discover the full pattern and re-analyze larger matching or non-matching parts, increasing successful vectorization.