Landing: dfd857530e0b
Project / Subsystem
gcc / tree-optimization
Date
2026-08-21
Author
Richard Biener
Commit
dfd857530e0bda541d4112c5c19bda0567b521ef
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- tree-optimization
- patch_id
- —
- commit_hash
- dfd857530e0bda541d4112c5c19bda0567b521ef
- source_type
- github
- headline
- Limit recursive PRE expression generation to avoid cycles.
- tldr
- Prevents infinite loops in PRE optimization by limiting recursive expression generation.
- author
- Richard Biener
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • optimization
- • PRE
- • SSA
- • compiler-bug
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-08-21T00:00:00.000Z
This commit limits the recursion depth during the generation of complex expressions within the PRE (Partial Redundancy Elimination) optimization pass. It was discovered that the value graph used by PRE can contain cycles, and recursive expression generation could enter infinite loops when encountering these cycles. A new test case exposed this issue, and the fix introduces a depth limit to prevent such recursions, ensuring stability and correctness of the PRE pass.