Dense Qwen retains duplicate attention and FP8 input staging across graph capacities

オープン
#46 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
説明が足りない
活発さ
活発
技術スタック
python
領域
performance

調査の方向性

Read the experimental branch linked in the issue and compare its scratch-bank capacity views with the upstream path at 1fd1f91. The issue does not name source files or tests to begin with; first trace the attention and FP8 input-staging lifetimes across graph capacities and full/recurrent layers. Done means a separately scoped implementation is chosen and validated on current main, with the stated regression and memory checks.

索引モデルが issue の本文から書いたものです。

説明

area:memory area:preparation model:qwen3.8-27b performance triage:verify-for-closure
Measured problem

The attention change at prefill 4096 is not GPU-qualified.

Dense Qwen constructor allocations retain full-attention and TensorFP8 input intermediates separately across graph capacities and across full/recurrent layers. Sharing the CUDA graph pool alone does not remove those allocations. This leaves less memory for native prefix cache and contributes to 32GB preparation pressure with the official target plus a parallel drafter.

The focused MLP issue (https://github.com/NVIDIA/flare-local-inference/issues/45) handles four MLP buffers independently. This issue records the remaining attention/input-staging work and offers a separate experimental implementation: https://github.com/Maxrio9/flare-local-inference/tree/qwen38-dense-memory-experiments-20261023, the combined MLP/attention follow-up to the DFlash2 proposal branch. It is not an independently rebased current-main fix.

Evidence

On RTX PRO4500 Blackwell/SM120/32GB, official nvidia/Qwen3.8-27B-NVFP4@482ca0f plus calibrated maurienne-ai/Qwen3.8-27B-DFlash2-NVFP4-RTNcal@bd7a934, C4/64K/prefill1024, 2GiB reserve:

  • native fixed mappings approximately22.23→22.07GiB;
  • final cache budget7.02GiB, KV-token ceiling192512→196608, snapshot slots30→31.

These limits share a physical memory budget and are not simultaneous per-request guarantees. Retained allocation totals are not measured live-memory peaks. No throughput improvement is claimed for this storage change.

The implementation binds seven disjoint BF16 attention fields and FP8 input staging through capacity views in the existing prefill/decode Scratch banks. Full and recurrent target layers consume input staging serially. Persistent caches, verification records and draft windows remain independent. Other recipes' context projections or overlapping branches must not inherit these aliases without their own lifetime analysis.

Validation boundary and requested direction

On the original experimental stack: two CPU storage/tail tests;69 state/ring,21 MTP and one compiled-scoring GPU check per memory stage;C4 inactive-hole coverage. Target full-vocabulary logits at18 fixed prefixes/512-row compiled graphs were bit-exact before/after. A64K/prefill1024 exported package passed native long-prefix reuse and capacity checks; a131072-context package passed130800prompt+128generated tokens. These are not current-main rebase results.

The qualified4096 package contains only the earlier MLP change. The optional22-prefix/1024-row comparison needs its corrected reference fixture rerun. Full other-model/shared-path regressions, FP8 draft KV and embedding offload are not claimed.

Would you prefer a separate attention/staging PR after the DFlash2 integration, or an ordinary-dense-only port first? Upstream was checked at1fd1f91; equivalent paths in other recipes need individual lifetime review rather than a general switch.

Authored and scratch-lifetime-reviewed by Codex (GPT-6), AI-assisted. Claude's review is limited to accounting, tests and reporting, not restricted Opus scratch-design work.

主要言語
Rust
スター
800
フォーク
106
平均マージ
1日 3時間
マージ済み PR(30日)
100

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

NVIDIA/hyperflare-inference のほかの issue

NVIDIA/hyperflare-inference の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。