Landing: f3c628585322

Project / Subsystem

gcc / ipa

Date

2026-09-02

Author

Richard Biener

Commit

f3c62858532248b2ee73e20f8d13019a4cb3a210

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
ipa
patch_id
—
commit_hash
f3c62858532248b2ee73e20f8d13019a4cb3a210
source_type
github
headline
IPA predicates avoid matching bit-field conditions against byte offsets.
tldr
Fixes IPA predicate matching to correctly handle bit-fields, preventing incorrect optimization and code generation issues.
author
Richard Biener
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • ipa
  • • optimization
  • • bit-fields
discussion_id_link
—
bugzilla_pr
—
date
2026-09-02T00:00:00.000Z

This commit addresses an issue where IPA predicates incorrectly matched bit-field conditions against byte offsets. The predicate conditions were stored as bit offsets, while jump function values used byte offsets. The existing logic divided bit offsets by 8, losing sub-byte position information and leading to incorrect matching. This caused a test case to misinterpret a bit-field, resulting in unreachable code elimination and a fall-through into _start. The fix ensures that lookups are skipped for non-byte-aligned conditions, resolving PR 126153.