Landing: fb0838bc1073
Project / Subsystem
gcc / gcc
Date
2026-07-15
Author
Richard Biener
Commit
fb0838bc1073aa5f22ec38e0cca2d70d625c6d71
Source
github
Perf win
Yes
Breaking
No
All attributes
- project
- gcc
- subsystem
- gcc
- patch_id
- —
- commit_hash
- fb0838bc1073aa5f22ec38e0cca2d70d625c6d71
- source_type
- github
- headline
- Support two-lane vector BB reductions without target support
- tldr
- GCC can now handle two-lane vector reductions even if the target doesn't explicitly support them, improving vectorization for certain cases.
- author
- Richard Biener
- outcome
- committed
- performance_win
- true
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • optimization
- • vectorization
- • x86
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-07-15T00:00:00.000Z
This commit enhances GCC’s loop vectorization to support reductions with two-lane vectors, even when the target architecture doesn’t provide specific reduc_*_scal optabs for such modes. It allows for more trivial handling of in-order reductions with two lanes. This change addresses issues like PR126028 on x86_64, where the lack of target support prevented optimal instruction matching. Some new, no-op vectorization cases may appear as the cost of vector operations now matches scalar ones in this scenario.