Landing: 0bf6e399dbc8

Project / Subsystem

gcc / gcc

Date

2026-08-05

Author

Andrew MacLeod

Commit

0bf6e399dbc8e1f6d2b3f7e0f3a0cab9ac55b572

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gcc
patch_id
—
commit_hash
0bf6e399dbc8e1f6d2b3f7e0f3a0cab9ac55b572
source_type
github
headline
Check for undefined in operator_lshift::op1_range.
tldr
GCC's left shift range analysis now correctly handles undefined results.
author
Andrew MacLeod
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • compiler
  • • optimization
  • • arithmetic
discussion_id_link
—
bugzilla_pr
—
date
2026-08-05T00:00:00.000Z

The operator_lshift::op1_range function in GCC’s range-op.cc has been updated to correctly handle cases where the result of a left shift operation is undefined. If an undefined result is detected, the calculation is now aborted, preventing potential inaccuracies in value range analysis.