Repository navigation
Conversation
Restore online FP8 and MXFP8 runtime state without requantizing cached weights. Preserve the CUTLASS logical width and avoid fusing NVFP4 MoE scales twice in shared IPC tensors. Add output-equivalence coverage and CI jobs. Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Restore attention scale metadata from cached buffers without consuming meta placeholders. Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Contributor
|
Documentation preview: https://vllm--63976.org.readthedocs.build/en/63976/ |
6 tasks done
Contributor
|
This pull request has merge conflicts that must be resolved before it can be |
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Preserve registered attention scales and zero points while restoring IPC host metadata. Update the existing attention regression to verify retained parameter identity and unchanged cached scales. Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Co-authored-by: Codex <noreply@openai.com> Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn>
Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn> Co-authored-by: Codex <noreply@openai.com>
Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn> Co-authored-by: Codex <noreply@openai.com>
Signed-off-by: liusy58 <mg21330037@smail.nju.edu.cn> Co-authored-by: Codex <noreply@openai.com>
Contributor
|
This pull request has merge conflicts that must be resolved before it can be |
6 tasks done
6 tasks done
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Enable weight-cache daemon restarts for serialized compressed-tensors W8A8 FP8 with CUTLASS 128×128 weight blocks. Related to #56049; depends on #63673 (and its prerequisite #63672).
Incremental review: liusy58/vllm@03b39f9...35e97cf (4 files; the diff against main also contains the prerequisites).
Claims
Validation
Current head
35e97cffd334c0732fed8ef0674138896faa373fincludes main914d61fc538a84e8487cb16fe8241a70f6f4bf9e. October 29 agent-run validation after resolving the inherited online-FP8 import conflict with upstream #60163. The merge retains both CUTLASS and Humming imports, the upstream processed-dimension metadata, and upstream rejection of the unsupported Humming per-token/channel path. It adds no Humming IPC capability.ct-block-layersct-block-modelct-block-llamaRuntime: NVIDIA B300, PyTorch 2.13.0+cu130, process-local CUDA 13.4 compatibility libraries. The two stable-libtorch extensions are from the official CUDA 13.0 wheel for main
914d61fc538a84e8487cb16fe8241a70f6f4bf9e, checked against wheel RECORD hashes and linked only into task worktrees. The shared venv and host driver were unchanged. This does not validate the full upstream PyTorch 2.14 dependency matrix.Full-model checks use TP1, BF16, eager mode, CUTLASS and TRITON_ATTN, with the existing batch-invariant exact greedy-output comparisons. Each completed case checks ordinary load, missing-daemon fallback, IPC and a second IPC load; both IPC loads forbid fallback. These are output-equivalence smoke checks, not accuracy or performance benchmarks. No multi-GPU, ROCm or other-backend result is claimed.
The temporary local helper calls the existing
run_cold_start_and_warm_restartwithdataclasses.replace(case, model=local_checkpoint, llm_kwargs={**case.llm_kwargs, "gpu_memory_utilization": 0.12})andVLLM_BATCH_INVARIANT=1. It changes only checkpoint location and the GPU memory budget; loading paths, prompts and assertions are unchanged. Online cases keep their checked-in 0.2 budget.Llama checkpoint:
RedHatAI/Meta-Llama-3.1-8B-FP8(redirected neuralmagic model), pinned881d74b74ad8ebe8775fb178b1fd0c935477f1bc. Upstream #62407 retained-Parameter behavior and the existing attention identity/shared-storage assertions remain intact.Block checkpoint:
RedHatAI/Qwen3-0.6B-FP8-BLOCK, pinned5def00c475640c0527e3a7067b1a26b94decefb5. Its model path is the existing cached model ID; the helper substitutes only the memory budget.Commands for this revision
All commands set
HF_HUB_OFFLINE=1,PYTHONPATHto the corresponding worktree andLD_LIBRARY_PATH=/home/liusy/codex-runtime/cuda-compat-13-4/usr/local/cuda-13.4/compat.CUDA_VISIBLE_DEVICES=2 .venv/bin/python -m pytest tests/quantization/test_compressed_tensors.py -k 'compressed_fp8_preprocessed or scheme_selection or get_quant_method or find_matched_target or get_scheme_dict or runtime_activation_order or accepts_preordered_weights or fp8_moe_forwards' -q CUDA_VISIBLE_DEVICES=2 CODEX_CACHE_VALIDATION_CASE=block .venv/bin/python -m pytest tests/model_executor/model_loader/_codex_oct29_validation.py -q CUDA_VISIBLE_DEVICES=2 CODEX_CACHE_VALIDATION_CASE=compressed CODEX_CACHE_MODEL_PATH=/home/liusy/codex-runtime/checkpoints/compressed-881d74b74a .venv/bin/python -m pytest tests/model_executor/model_loader/_codex_oct29_validation.py -qGitHub checks for the new head are pending at publication. No Buildkite GPU-suite pass or completed human review is claimed. AI assistance and original feature baselines are recorded below.
Earlier validation and original feature baselines (previous heads)
Earlier head
fb04cad37dda54a727d03f021718a18f540a5d65includes main36d4ef654a83e227216b0c0b55cf4041d96b1675. Agent-run B300 validation on October 29, after synchronizing the native extensions with that main commit:Conflict resolution preserves upstream #62407 parameter registration while retaining IPC attention-scale restoration. The two existing attention tests now assert that post-load keeps the attached Parameter objects, shares the source storage, preserves exact scale values, and reconstructs CPU scale metadata from cached buffers.
The Llama case uses
RedHatAI/Meta-Llama-3.1-8B-FP8(the redirected neuralmagic model) pinned at881d74b74ad8ebe8775fb178b1fd0c935477f1bc.The temporary local wrapper calls the existing
run_cold_start_and_warm_restartwith only the checkpoint directory andgpu_memory_utilization=0.12substituted; assertions and loading paths are unchanged. The block checkpoint remainsRedHatAI/Qwen3-0.6B-FP8-BLOCKpinned at5def00c475640c0527e3a7067b1a26b94decefb5, also using memory fraction0.12.B300, TP1, BF16, eager mode, CUTLASS linear kernels and TRITON_ATTN. Full-model cases exercise ordinary loading → missing-daemon fallback → IPC → second IPC, with fallback forbidden on both IPC loads and the existing exact batch-invariant greedy-output comparisons unchanged. These are output-equivalence smoke tests, not accuracy or performance benchmarks; multi-GPU and other hardware are not claimed.
Runtime: PyTorch 2.13.0+cu130 with process-local CUDA 13.4 compatibility libraries. The two stable-libtorch native extensions were taken from the official CUDA 13.0 wheel for exact main
36d4ef654a83e227216b0c0b55cf4041d96b1675, verified against wheel RECORD hashes, and linked only into the task worktrees. Their declared stable ABI supports PyTorch >=2.11. This is not validation of the complete upstream PyTorch 2.14 dependency matrix; the shared venv and host driver were unchanged.An initial Llama run stalled reading the shared NFS checkpoint; it was stopped and rerun using a pinned local-disk checkpoint. An initial NVFP4 ordinary load failed before IPC because the old native extension exposed an 11-argument operator while current source required 12; the matching extensions above resolved that environment mismatch. Neither initial run is counted as a passing test or as a cache regression. All results in the table use the matching extensions. Existing torch/fork deprecation warnings are retained in the logs.
The exact heads above are MERGEABLE; GitHub pre-commit, DCO and Read the Docs passed on October 29. No Buildkite GPU-suite success or completed human review is claimed. Original feature baselines and earlier results remain below and are not reruns of the October 29 conflict resolution.
Original feature baselines, reproduction commands and earlier validation
NVIDIA B300, TP1, BF16, CUTLASS linear backend. Real-model checks use eager mode, TRITON_ATTN and
VLLM_BATCH_INVARIANT=1, comparing ordinary loading → missing-daemon fallback → IPC → second IPC. Both IPC loads prohibit fallback. Each case compares exact greedy outputs for two prompts × 16 generated tokens.4f9c3c8c06plus new testsRedHatAI/Qwen3-0.6B-FP8-BLOCK, pinned5def00c475640c0527e3a7067b1a26b94decefb5The Llama regression uses the existing local
Meta-Llama-3.1-8B-FP8checkpoint, with only its model path substituted; checked-in settings and assertions are unchanged. A first combined run passed the block case but failed to locate the Llama HF ID in the offline cache; the local-path rerun above passed both cases. These are smoke output-equivalence checks, not broad accuracy or performance benchmarks. Multi-GPU and other platforms are not claimed.Reproduction commands and baseline output
HF_HUB_OFFLINE=1assumes the pinned checkpoint and OPT-125m configuration are cached; omit it for the initial download. Before implementation, the first command failed after successful ordinary/fallback generation:The block layer baseline reported:
For the two-model regression on this machine, a temporary test next to
test_weight_cache.pycalls the checked-in test withreplace(suite.COMPRESSED_FP8_CASE, model="/mnt/minecraft/model/Meta-Llama-3.1-8B-FP8")andsuite.COMPRESSED_BLOCK_FP8_CASE. It changes no production behavior or expectations. Run it with the same environment and-q; on a machine with both HF checkpoints cached, select-k compressed_fp8directly. Runs emitted existing torch/fork deprecation warnings.Details
The previous capability gate accepts only the tensor/channel CUTLASS kernel. Block FP8 uses a different kernel and keeps weights in
[N, K]layout, so accepting it also requires avoiding the tensor/channel path's transposed-layout metadata. Opt in only the actualCutlassFp8BlockScaledMMKernelwith[128, 128]blocks, retain the dynamicinput_scale=Nonerestoration, and return before any second weight transformation. The kernel constructor already initializes dynamic group-128 activation quantization and its scale layout. No new common loading interface, scheduler/model-runner path, or steady-state GPU synchronization.The existing B200 Quantized Preload CI selection includes both model parameterizations and the extended real-layer test; its source dependencies cover the changed tests and quantization code. Local validation used B300; B200 Buildkite execution is not claimed. The preload feature guide documents the format, matching CUTLASS selection in daemon and engine, and exclusions. Other block sizes/backends, W8A16 fallback, transform wrappers and MoE remain outside this change.
Duplicate checks on October 27 covered #56049/comments, issue-linked PRs and open block-FP8/preload searches. #63673 adds tensor/channel FP8 only; #60015 fixes W8A16 checkpoint scale naming, and #62407 handles generic reload parameter retirement/aliases. Neither implements this W8A8 block-FP8 IPC path. The current branch includes main
914d61fc538a; its #62407 parameter-retention contract is preserved.AI assistance: Codex implemented and ran the recorded validation at the submitter's request. This draft is for human review; no completed human approval or human-run tests are asserted.
Pull Request Checklist
I used vLLM's
/pr-checklistskill. (Mandatory for agents, optional for humans).AI assistance was used during the creation of this PR.
Design Fit: Narrow capability opt-in and correct block layout metadata, reusing existing interfaces.
Testing and Validation: Real checkpoint and layer before/after, regression results and CI resource limits recorded above.
Code Quality and Style: Changed-file hooks passed; preload feature documentation updated.
Pull Request Contents: Root cause, prerequisites, duplicate checks, commands, evidence, limitations and AI disclosure included.