Landing: 35b4c01575e1

Project / Subsystem

gcc / gcc

Date

2026-09-28

Author

Richard Biener

Commit

35b4c01575e15550b49c82fe146b2669db6320a7

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gcc
patch_id
—
commit_hash
35b4c01575e15550b49c82fe146b2669db6320a7
source_type
github
headline
Correctly handle COMPCODE_FALSE/TRUE trapping in combine_comparisons
tldr
Fixes floating-point exception handling by ensuring combine_comparisons doesn't incorrectly flag boolean comparison results as trapping.
author
Richard Biener
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • optimization
  • • floating-point
  • • bugfix
discussion_id_link
—
bugzilla_pr
—
date
2026-09-28T00:00:00.000Z

This commit corrects a bug in GCC’s combine_comparisons function where COMPCODE_FALSE and COMPCODE_TRUE were erroneously treated as trapping operations when floating-point trapping was enabled. This led to the elimination of necessary IEEE exceptions. The fix modifies the condition that determines if a comparison traps, ensuring that these boolean outcomes do not trigger the trapping logic, thereby preserving correct floating-point exception behavior.