Landing: 2f5ed170082f

Project / Subsystem

gcc / gcc

Date

2026-08-01

Author

Jakub Jelinek

Commit

2f5ed170082f9f2401a0c1c4a18e538c0cf75013

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gcc
patch_id
—
commit_hash
2f5ed170082f9f2401a0c1c4a18e538c0cf75013
source_type
github
headline
Simplify conditional expressions.
tldr
Removes redundant ternary operations like `condition ? true : false` and `condition ? false : true`.
author
Jakub Jelinek
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • refactoring
  • • code-cleanup
  • • simplification
  • • fortran
discussion_id_link
—
bugzilla_pr
—
date
2026-08-01T00:00:00.000Z

This commit cleans up the GCC codebase by removing several instances of verbose conditional expressions. It replaces patterns like condition ? true : false with the condition itself, and condition ? false : true with the negation of the condition (!condition). This simplification improves code readability and maintainability across various internal compiler files, including ipa-polymorphic-call.cc, tree-ssa-loop-im.cc, match.pd, and Fortran-specific files.