Landing: 6ddf635c9c69
Project / Subsystem
gcc / compare-elim
Date
2026-07-30
Author
Kyrylo Tkachov
Commit
6ddf635c9c694dcdf5a5e490592f71b65c7e278f
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- compare-elim
- patch_id
- —
- commit_hash
- 6ddf635c9c694dcdf5a5e490592f71b65c7e278f
- source_type
- github
- headline
- compare-elim: Test successor's live-in set for flags register
- tldr
- Corrects compare-elim pass to accurately check flag register liveness across basic block boundaries.
- author
- Kyrylo Tkachov
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • optimization
- • compiler
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-07-30T00:00:00.000Z
The compare-elimination pass incorrectly checked the live-in set of the current basic block instead of its successor when determining if the flags register was used in a join block. This commit corrects the pass to query the successor’s live-in set, ensuring that comparisons whose flags are live across block boundaries are properly identified and handled, preventing potential issues in join blocks.