Repository navigation
Fix select and normalized logprobs - #67
Merged
Merged
Conversation
5 tasks done
timethink
pushed a commit
to timethink/sglang
that referenced
this pull request
Mar 9, 2025
chunyuan-w
added a commit
to chunyuan-w/sglang
that referenced
this pull request
May 12, 2025
* sgl-kernel: add forward_absorb_decode_fused_cpu kernel for DeepSeek * remove ops.h and define functions as extern * Call forward_absorb_decode_fused_cpu in DeepSeek decode * Update FP8 qkv_proj_with_rope related code after rebase * Add fused forward func for DeepseekV2MoE * refine comment
NorthmanPKU
pushed a commit
to NorthmanPKU/sglang
that referenced
this pull request
May 16, 2025
* checkpoint * checkpoint * checkpoint * finish range propagation * format * fix * support various forloop accum operators & bug fix * deprecate ExecutionPlan and switch back to DFS * format --------- Co-authored-by: Mengdi Wu <[email protected]>
zhuyijie88
pushed a commit
to zhuyijie88/sglang
that referenced
this pull request
Sep 4, 2025
* Update pre-downloaded-models.ini
key4ng
pushed a commit
to key4ng/sglang
that referenced
this pull request
Nov 9, 2025
vschandramourya
pushed a commit
to vschandramourya/sglang
that referenced
this pull request
Feb 3, 2026
* add phoenix * fix suffix tree * fix eagle * fix spec enum * fix phoenix * resolve upstream conflict * format * fix typo * fix model override * revert registry.py * fix dsv3 * loading phx weights * fix phx weight load * fix mpt weight loading for nvfp4 target model. * fix phx bug and faster than eagle MTP * format * remove unnessary cudagraph file --------- Co-authored-by: Junxiong Wang <[email protected]> Co-authored-by: Jue WANG <[email protected]> Co-authored-by: Jue Wang <[email protected]> Co-authored-by: Jue Wang <[email protected]>
5 tasks done
WhiteCmile
added a commit
to WhiteCmile/sglang
that referenced
this pull request
Oct 27, 2026
…rtup floor CI review on PR sgl-project#67 (round 2): - The launcher default is a default, not a minimum: ring-published waves are capped at scheduler.max_running_requests and a slot is freed whenever a verify consumes it, so any slot count backpressures instead of deadlocking, and standalone/ring-disabled configs never run the whole-wave gate at all. Drop the startup ValueError that crashed such Targets; an explicit --candidate-slots below the default is valid again. - On exhaustion, hold only the blocked session's later waves (per-session confirmation order) and keep confirming other sessions' waves, instead of retaining every pending wave and breaking out globally. Removes the cross-session head-of-line blocking under overload.
WhiteCmile
added a commit
to WhiteCmile/sglang
that referenced
this pull request
Oct 27, 2026
Controller review on PR sgl-project#67 (round 4): the whole-wave free-slot gate in _ring_publish_cleanup can never admit a wave when the arena is smaller than one wave, wedging every ring-published wave forever. Restore a startup floor, but the right one: an explicit --candidate-slots must be at least dt_direct_ring.V2_MAX_REQ (56), the largest wave the ring can publish, so an empty arena always admits any wave. 256 stays legal; the old floor of 2x max_running_requests was the wrong floor. The constant is imported, not restated.
WhiteCmile
added a commit
to WhiteCmile/sglang
that referenced
this pull request
Oct 27, 2026
Controller review on PR sgl-project#67 (round 4): every wave in _ring_publish_pending had its publish kernel launched, so its record may already be on the ring even when no confirmation task was queued; the Draft can pull such a source before any Coordinator confirmation, so releasing the slot to FREE at shutdown could recycle it under a reader. Quarantine pending waves instead (quarantine is always safe at shutdown), and let TargetFeatureSourcePool.close() accept QUARANTINED slots - quarantine already fences them from reuse permanently - so the 15 s grace exit still succeeds. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
yicyang
added a commit
to yicyang/sglang
that referenced
this pull request
Nov 9, 2026
* [AMD] Make R-Fork (remote_instance, nccl) work for Qwen3.8-Flash-Next FP8 on MI308X - Client runs quant post-processing before receiving so tensor layout/dtype (fnuz, PyHIP GR packing) matches the seed. - Recompute load-time derived buffers (gemma_weight) after the raw copy. - Exchange a (name, shape, dtype) manifest digest before broadcasting; a mismatch now fails fast on both sides instead of deadlocking RCCL (seed RoPE caches grow at runtime). - Seed no longer crashes when a send group failed to init; client checks build_group result. - SGLANG_DEBUG_WEIGHT_CHECKSUM_DIR: per-rank post-load checksums. - Client launch script and validation report (benchmark/rfork_mi308x). * [AMD] Validate ModelExpress-style startup paths on MI308X; fix Mooncake HIP R-Fork - R-Fork transfer_engine: on ROCm register whole allocator segments, working around Mooncake HIP transport resolving addresses from the IPC allocation base (silently wrong weights otherwise); add standalone repro. - R-Fork transfer_engine: recompute derived buffers after the copy. - Benchmark tools: startup timer, per-model page-cache eviction, first-request latency, raw fastsafetensors throughput, weight-cache daemon shim. - Report: kernel-cache transfer, storage loaders (fastsafetensors, runai, prefetch, no-mmap), Mooncake vs RCCL, weight_cache limitation. * benchmark/rfork_mi308x: add per-phase startup time breakdown * Add weight-iterator timing debug switch; report per-rank disk read vs load_weights and full launch commands SGLANG_DEBUG_WEIGHT_ITER_TIMING logs time blocked on the checkpoint iterator vs time in load_weights, and splits fastsafetensors into file read and per-tensor distribution. * benchmark/rfork_mi308x: add bench_startup.py startup-time matrix * benchmark/rfork_mi308x: add TP2 results and seed-stall finding * benchmark/rfork_mi308x: correct runai/no-mmap memory note (peak only, KV unaffected) * remote_instance: refresh KV-cache scale floats after receiving weights Receivers run process_weights_after_loading before the copy, which sets k_scale_float/v_scale_float from the -1 placeholders (1.0). The copy then brings the seed's final k/v_scale tensors, but the floats consumed by the attention backends stayed at 1.0 for checkpoints with non-unit KV scales. Refresh them from the received tensors next to the alias rebind. * benchmark/rfork_mi308x: make bench_startup cache/GPU state explicit - warm page cache is now prepared (read in) and verified like cold; abort if residency is not reached (O_DIRECT loaders left "warm" runs cold) - remove a stale log before launch so an old "fired up" is not taken as ready - non-R-Fork runs use HIP_VISIBLE_DEVICES (fastsafetensors uses cuda:rank and ignores --base-gpu-id); R-Fork ranges must be contiguous, equal size, disjoint - refuse to launch on GPUs with >2 GiB in use; interleave repeats * benchmark/rfork_mi308x: add verify_rfork.py; rewrite README with TP2/TP4 rerun Full rerun at 378743602 with the same scripts and table layout for TP2 and TP4: startup matrix (6 configs x page cache warm/cold x 2), cold kernel cache, per-rank checksums and GSM8K for disk/RCCL/Mooncake. README shortened; adds script usage. * benchmark/rfork_mi308x: clarify R-Fork cold page-cache cells were not run * benchmark/rfork_mi308x: measure R-Fork configs with a cold page cache too * Trim PR to necessary changes Drop what was only used for analysis or convenience: - RCCL transfer manifest check (guarded a buffer-transfer variant that is not used; parameters-only transfer as before) - SGLANG_DEBUG_WEIGHT_ITER_TIMING and the iterator/fastsafetensors timers - rfork client launch script and analysis-only benchmark tools * benchmark/rfork_mi308x: README with usage and results only * benchmark/rfork_mi308x: drop prefetch config and results (no gain measured) * benchmark/rfork_mi308x: stop the seed when a run aborts * load_model_utils: correct the checksum peak-memory comment * scripts: add a reference launcher for the fast-startup options * scripts: add a cross-container R-Fork reference launcher Starts the new instance in its own container on the same node (host network, shared IPC, GPU devices) and runs MODE=rfork against a seed in another container. CROSS_CONTAINER.md lists the requirements, usage and one TP2 measurement. * Drop Mooncake, storage loaders and seed-startup options; keep R-Fork over RCCL - transfer_engine path is back to the base branch: no whole-segment registration workaround, no pre-receive processing or derived-state restore for it (both now NCCL only) - remove mooncake_hip_offset_repro.py - bench_startup.py: configs disk and rfork_nccl only; drop the kernel-cache option; place every run with HIP_VISIBLE_DEVICES - verify_rfork.py: disk seed + RCCL instance only - launcher renamed to launch_qwen38_flash_next_fp8_mi308x_rfork.sh with MODE=seed|rfork; cross-container launcher is RCCL only - README: R-Fork scale-out effect, dependencies (none beyond ROCm), usage * benchmark/rfork_mi308x: README results from the TP2 re-run at the RCCL-only head * benchmark/rfork_mi308x: README TP2 results re-measured at the rebased head --------- Co-authored-by: yicyang <[email protected]> (cherry picked from commit 6ca1975 on qwen38-flash-next-amd-current-fix-install) Conflicts resolved in loader.py (post_load_weights rename, import block) and load_model_utils.py (PLE offload condition now read via get_exec()). Signed-off-by: yicyang <[email protected]> Signed-off-by: Ethan Yang <[email protected]>
yicyang
added a commit
to yicyang/sglang
that referenced
this pull request
Nov 10, 2026
* Fix R-Fork weight loading on MI308X (sgl-project#67) * [AMD] Make R-Fork (remote_instance, nccl) work for Qwen3.8-Flash-Next FP8 on MI308X - Client runs quant post-processing before receiving so tensor layout/dtype (fnuz, PyHIP GR packing) matches the seed. - Recompute load-time derived buffers (gemma_weight) after the raw copy. - Exchange a (name, shape, dtype) manifest digest before broadcasting; a mismatch now fails fast on both sides instead of deadlocking RCCL (seed RoPE caches grow at runtime). - Seed no longer crashes when a send group failed to init; client checks build_group result. - SGLANG_DEBUG_WEIGHT_CHECKSUM_DIR: per-rank post-load checksums. - Client launch script and validation report (benchmark/rfork_mi308x). * [AMD] Validate ModelExpress-style startup paths on MI308X; fix Mooncake HIP R-Fork - R-Fork transfer_engine: on ROCm register whole allocator segments, working around Mooncake HIP transport resolving addresses from the IPC allocation base (silently wrong weights otherwise); add standalone repro. - R-Fork transfer_engine: recompute derived buffers after the copy. - Benchmark tools: startup timer, per-model page-cache eviction, first-request latency, raw fastsafetensors throughput, weight-cache daemon shim. - Report: kernel-cache transfer, storage loaders (fastsafetensors, runai, prefetch, no-mmap), Mooncake vs RCCL, weight_cache limitation. * benchmark/rfork_mi308x: add per-phase startup time breakdown * Add weight-iterator timing debug switch; report per-rank disk read vs load_weights and full launch commands SGLANG_DEBUG_WEIGHT_ITER_TIMING logs time blocked on the checkpoint iterator vs time in load_weights, and splits fastsafetensors into file read and per-tensor distribution. * benchmark/rfork_mi308x: add bench_startup.py startup-time matrix * benchmark/rfork_mi308x: add TP2 results and seed-stall finding * benchmark/rfork_mi308x: correct runai/no-mmap memory note (peak only, KV unaffected) * remote_instance: refresh KV-cache scale floats after receiving weights Receivers run process_weights_after_loading before the copy, which sets k_scale_float/v_scale_float from the -1 placeholders (1.0). The copy then brings the seed's final k/v_scale tensors, but the floats consumed by the attention backends stayed at 1.0 for checkpoints with non-unit KV scales. Refresh them from the received tensors next to the alias rebind. * benchmark/rfork_mi308x: make bench_startup cache/GPU state explicit - warm page cache is now prepared (read in) and verified like cold; abort if residency is not reached (O_DIRECT loaders left "warm" runs cold) - remove a stale log before launch so an old "fired up" is not taken as ready - non-R-Fork runs use HIP_VISIBLE_DEVICES (fastsafetensors uses cuda:rank and ignores --base-gpu-id); R-Fork ranges must be contiguous, equal size, disjoint - refuse to launch on GPUs with >2 GiB in use; interleave repeats * benchmark/rfork_mi308x: add verify_rfork.py; rewrite README with TP2/TP4 rerun Full rerun at 378743602 with the same scripts and table layout for TP2 and TP4: startup matrix (6 configs x page cache warm/cold x 2), cold kernel cache, per-rank checksums and GSM8K for disk/RCCL/Mooncake. README shortened; adds script usage. * benchmark/rfork_mi308x: clarify R-Fork cold page-cache cells were not run * benchmark/rfork_mi308x: measure R-Fork configs with a cold page cache too * Trim PR to necessary changes Drop what was only used for analysis or convenience: - RCCL transfer manifest check (guarded a buffer-transfer variant that is not used; parameters-only transfer as before) - SGLANG_DEBUG_WEIGHT_ITER_TIMING and the iterator/fastsafetensors timers - rfork client launch script and analysis-only benchmark tools * benchmark/rfork_mi308x: README with usage and results only * benchmark/rfork_mi308x: drop prefetch config and results (no gain measured) * benchmark/rfork_mi308x: stop the seed when a run aborts * load_model_utils: correct the checksum peak-memory comment * scripts: add a reference launcher for the fast-startup options * scripts: add a cross-container R-Fork reference launcher Starts the new instance in its own container on the same node (host network, shared IPC, GPU devices) and runs MODE=rfork against a seed in another container. CROSS_CONTAINER.md lists the requirements, usage and one TP2 measurement. * Drop Mooncake, storage loaders and seed-startup options; keep R-Fork over RCCL - transfer_engine path is back to the base branch: no whole-segment registration workaround, no pre-receive processing or derived-state restore for it (both now NCCL only) - remove mooncake_hip_offset_repro.py - bench_startup.py: configs disk and rfork_nccl only; drop the kernel-cache option; place every run with HIP_VISIBLE_DEVICES - verify_rfork.py: disk seed + RCCL instance only - launcher renamed to launch_qwen38_flash_next_fp8_mi308x_rfork.sh with MODE=seed|rfork; cross-container launcher is RCCL only - README: R-Fork scale-out effect, dependencies (none beyond ROCm), usage * benchmark/rfork_mi308x: README results from the TP2 re-run at the RCCL-only head * benchmark/rfork_mi308x: README TP2 results re-measured at the rebased head --------- Co-authored-by: yicyang <[email protected]> (cherry picked from commit 6ca1975 on qwen38-flash-next-amd-current-fix-install) Conflicts resolved in loader.py (post_load_weights rename, import block) and load_model_utils.py (PLE offload condition now read via get_exec()). Signed-off-by: yicyang <[email protected]> Signed-off-by: Ethan Yang <[email protected]> * R-Fork: adapt the cherry-picked scripts to qwen4_v0.5.21 Launch scripts live in evaluation/ on this branch, so move the R-Fork launchers there and point bench_startup.py at evaluation/. The base launch script defaults MTP=1 here; R-Fork is validated without the MTP draft model, so the R-Fork launcher and bench_startup.py default MTP=0. Signed-off-by: yicyang <[email protected]> * [CI] Add a same-container TP2 R-Fork case to the Qwen4 CI Qwen3.8-Flash-TP2-RFork starts a TP2 seed from disk, then a TP2 instance on two other idle GPUs that pulls the seed's weights over RCCL (--load-format remote_instance). It fails unless the new instance loads via R-Fork, every rank's per-tensor checksums match the seed, and the new instance passes the TP2 GSM8K gate (reference 98.0%). The summary also reports the new instance's startup time and load_weight. Under --pressure it only checks loading and checksums. Signed-off-by: yicyang <[email protected]> * R-Fork cross-container launcher: drop the private workspace mount The launcher no longer requires or mounts a host workspace directory. The new container runs the image's SGLang at REPO_DIR (default /opt/sglang); DOCKER_ARGS passes extra docker run arguments, e.g. a mount for a host checkout used with REPO_DIR. Signed-off-by: yicyang <[email protected]> * [CI] Run the R-Fork case in the daily schedule only; drop README footnotes - Qwen3.8-Flash-TP2-RFork is daily-only: PR runs skip it, the daily schedule and an explicit case selection run it. matrix_cases() in qwen4_ci.py now builds the Actions matrix and is unit tested. - Under --pressure the R-Fork case also checks the complete seed and server logs after shutdown, like the other pressure cases. - README: remove the measurement footnotes. Signed-off-by: yicyang <[email protected]> --------- Signed-off-by: yicyang <[email protected]> Signed-off-by: Ethan Yang <[email protected]> Co-authored-by: yicyang <[email protected]>
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.
No description provided.