Landing: c65691bc5a28

Project / Subsystem

gcc / gcc

Date

2026-04-29

Author

Andrew Pinski

Commit

c65691bc5a2873e0e2ffbfcaa80eb9bdc6e1f7b8

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gcc
patch_id
commit_hash
c65691bc5a2873e0e2ffbfcaa80eb9bdc6e1f7b8
source_type
github
headline
Match: Simplify patterns for `a != b` implies a or b is non-zero
tldr
The compiler's pattern-matching code for simplifying logical expressions is now more concise.
author
Andrew Pinski
outcome
committed
performance_win
false
breaking_change
false
series_id
series_parts
[]
tags
  • optimization
  • pattern matching
  • code generation
discussion_id_link
bugzilla_pr
date
2026-04-29T00:00:00.000Z

The compiler’s pattern-matching rules for expressions of the form (a != b) &| ((a|b) ==/!= 0) are now defined using a for loop, which simplifies the code and shrinks the generated gimple-match*.cc files by about 300 lines. The c: constraint in the inner ne/eq pattern is now redundant and has been removed.