Landing: d0e28326d425

Project / Subsystem

gcc / tree-optimization

Date

2026-09-21

Author

Naveen

Commit

d0e28326d4254e4824096a7331c8600455c22f73

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
tree-optimization
patch_id
—
commit_hash
d0e28326d4254e4824096a7331c8600455c22f73
source_type
github
headline
Fold redundant integer-float-integer conversions
tldr
Optimizes redundant int->float->int conversions when precision is maintained.
author
Naveen
outcome
committed
performance_win
true
breaking_change
false
series_id
—
series_parts
[]
tags
  • • optimization
  • • tree-ssa
  • • floating-point
discussion_id_link
—
bugzilla_pr
—
date
2026-09-21T00:00:00.000Z

This optimization folds redundant integer-to-floating-point-to-integer conversions when the intermediate floating-point type can precisely represent all values of the final integer type. This improves code efficiency by eliminating unnecessary conversions, especially when the -fno-trapping-math option is enabled and the floating-point significand has sufficient precision.