Landing: d6d21c3abd31

Project / Subsystem

gcc / gcc/ivopts

Date

2026-04-27

Author

Andrew Pinski

Commit

d6d21c3abd31b73146df15b626da544eb4a8509a

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
gcc/ivopts
patch_id
commit_hash
d6d21c3abd31b73146df15b626da544eb4a8509a
source_type
github
headline
Ivopts: Improve doloop support for enum and bitint types
tldr
Extends doloop recognition to enum and bitint types by converting them to a full mode integer type.
author
Andrew Pinski
outcome
committed
performance_win
true
breaking_change
false
series_id
series_parts
[]
tags
  • optimization
  • loop
  • enum
  • bitint
discussion_id_link
bugzilla_pr
date
2026-04-27T00:00:00.000Z

This commit extends the loop induction variable (iv) optimization to handle enum and bitint types. Previously, the add_iv_candidate_for_doloop function only supported integer types. This commit modifies the function to accept non-integer types, converting them to a full mode integer type before processing. This change enables doloop optimization for loops using enum and bitint types as induction variables.