Landing: afa9dd376907

Project / Subsystem

gcc / scheduler

Date

2026-09-14

Author

xiezhiheng

Commit

afa9dd3769077c50180865f53bf2ff8abb0a2f97

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
scheduler
patch_id
—
commit_hash
afa9dd3769077c50180865f53bf2ff8abb0a2f97
source_type
github
headline
sched: Cap max_lookahead_tries to prevent overflow
tldr
Prevents scheduler overflow on modern cores by capping `max_lookahead_tries`.
author
xiezhiheng
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • scheduler
  • • AArch64
  • • overflow
  • • optimization
discussion_id_link
—
bugzilla_pr
—
date
2026-09-14T00:00:00.000Z

The issue rate on modern CPU cores has been increasing, leading to a value of 10 in the AArch64 backend’s max_issue calculation. This caused an integer overflow when calculating max_lookahead_tries. This commit caps max_lookahead_tries to prevent this overflow, ensuring the scheduler operates correctly. The change is a small but crucial fix for handling high issue rates on contemporary hardware.