Widen specialized int fast paths to full int64 range
オープン
まだ誰も着手していません。
interpreter-core
performance
type-feature
- 主要言語
- Python
- スター
- 77.2k
- フォーク
- 35.9k
- PR マージ指標
- PR 指標を取得中
説明
This work widens the interpreter’s specialized int fast paths (tier-2 / uop execution) from the compact-only range to the full int64_t range.
It also fixes follow-up correctness issues in the widened specialized paths for non-compact exact PyLongObjects and on 15-bit builds.
Scope:
- widen specialized integer add/subtract/multiply fast paths to operate across the full
int64_trange - accept exact
intoperands that fit inint64_t, including non-compactPyLongObjects - keep specialized in-place mutation compact-only and fall back safely for non-compact inputs
- handle widened integer compare without compact-only assumptions
- construct widened arithmetic results with
PyLong_FromInt64()so 15-bit builds do not narrow throughstwodigits - add regression coverage for widened operations, non-compact exact ints, boundary cases, and overflow fallback
- add benchmark scripts for measuring widened specialized integer fast-path performance
Linked PRs
- gh-150425
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、インタープリターの tier-2/uop における整数の加算、減算、乗算、比較用の特殊化された高速パスを、PyLongObject オペランドの処理も含めて見つけます。拡張された演算向けに追加されたリグレッションカバレッジとベンチマークスクリプトを確認し、その後、int64_t の全範囲の境界、非コンパクトな Exact Int、オーバーフロー時のフォールバック、インプレースミューテーションの挙動、15-bit ビルドを検証します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- c, python
- 領域
- compilers
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 25/100