Landing: 81a34bdbcb3e
Project / Subsystem
gcc / middle-end
Date
2026-08-14
Author
Kyrylo Tkachov
Commit
81a34bdbcb3e27a8fb2438fd90bbb76ec506fb40
Source
github
Perf win
Yes
Breaking
No
All attributes
- project
- gcc
- subsystem
- middle-end
- patch_id
- —
- commit_hash
- 81a34bdbcb3e27a8fb2438fd90bbb76ec506fb40
- source_type
- github
- headline
- Do not widen multiply-add across shared conversion
- tldr
- Fixes a bug where a multiply-add was incorrectly widened, leading to performance regressions.
- author
- Kyrylo Tkachov
- outcome
- committed
- performance_win
- true
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • optimization
- • aarch64
- • performance
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-08-14T00:00:00.000Z
The convert_plusminus_to_widen optimization pass incorrectly widened multiply-add operations when a conversion was involved. This pass requires the multiply operation to be single-use, but the conversion meant the multiply’s result was shared, causing the pass to apply the widening to the wrong value. This change ensures the single-use requirement applies to the conversion’s result, preventing the generation of redundant multiply operations. This optimization was found in a sparse affine kernel and resulted in a 4.7% instruction count reduction on AArch64.