From b14590a8abe90be0ebe36c8a28b0f26fa4e2ae67 Mon Sep 17 00:00:00 2001 From: functionstackx <47992694+functionstackx@users.noreply.github.com> Date: Fri, 17 Apr 2026 01:56:37 -0400 Subject: [PATCH 1/4] Add B300 config: dsr1-fp4-sglang (non-MTP) The SGLang cookbook does not have a B300-specific DSR1 FP4 recipe, so this config reuses the existing B200 DSR1 FP4 SGLang recipe as-is until B300- specific tuning is available. Image bumped to v0.5.10.post1-cu130 to match the standard B300 SGLang image used by other B300 configs. Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/configs/nvidia-master.yaml | 20 ++++++ benchmarks/single_node/dsr1_fp4_b300.sh | 81 +++++++++++++++++++++++++ perf-changelog.yaml | 8 +++ 3 files changed, 109 insertions(+) create mode 100644 benchmarks/single_node/dsr1_fp4_b300.sh diff --git a/.github/configs/nvidia-master.yaml b/.github/configs/nvidia-master.yaml index 5b550879c..5a4deb032 100644 --- a/.github/configs/nvidia-master.yaml +++ b/.github/configs/nvidia-master.yaml @@ -1669,6 +1669,26 @@ dsr1-fp4-b200-sglang: - { tp: 4, ep: 4, conc-start: 4, conc-end: 128 } - { tp: 8, ep: 8, conc-start: 4, conc-end: 16 } +dsr1-fp4-b300-sglang: + image: lmsysorg/sglang:v0.5.10.post1-cu130 + model: nvidia/DeepSeek-R1-0528-FP4-V2 + model-prefix: dsr1 + runner: b300 + precision: fp4 + framework: sglang + multinode: false + seq-len-configs: + - isl: 1024 + osl: 1024 + search-space: + - { tp: 4, ep: 4, conc-start: 4, conc-end: 128 } + - { tp: 8, ep: 8, conc-start: 4, conc-end: 128 } + - isl: 8192 + osl: 1024 + search-space: + - { tp: 4, ep: 4, conc-start: 4, conc-end: 128 } + - { tp: 8, ep: 8, conc-start: 4, conc-end: 16 } + dsr1-fp4-b200-trt: image: nvcr.io#nvidia/tensorrt-llm/release:1.2.0rc6.post2 model: nvidia/DeepSeek-R1-0528-FP4-V2 diff --git a/benchmarks/single_node/dsr1_fp4_b300.sh b/benchmarks/single_node/dsr1_fp4_b300.sh new file mode 100644 index 000000000..4530eda7d --- /dev/null +++ b/benchmarks/single_node/dsr1_fp4_b300.sh @@ -0,0 +1,81 @@ +#!/usr/bin/env bash + +# NOTE: https://cookbook.sglang.io/autoregressive/DeepSeek/DeepSeek-R1 does not +# have a B300-specific recipe, so this script reuses the existing DSR1 FP4 B200 +# SGLang recipe as-is until B300-specific tuning is available. + +source "$(dirname "$0")/../benchmark_lib.sh" + +check_env_vars \ + MODEL \ + TP \ + CONC \ + ISL \ + OSL \ + RANDOM_RANGE_RATIO \ + RESULT_FILENAME \ + EP_SIZE + +if [[ -n "$SLURM_JOB_ID" ]]; then + echo "JOB $SLURM_JOB_ID running on $SLURMD_NODENAME" +fi + +hf download "$MODEL" + +nvidia-smi + +SERVER_LOG=/workspace/server.log +PORT=${PORT:-8888} + +# Default: recv every ~10 requests; if CONC ≥ 16, relax to ~30 requests between scheduler recv polls. +if [[ $CONC -ge 16 ]]; then + SCHEDULER_RECV_INTERVAL=30 +else + SCHEDULER_RECV_INTERVAL=10 +fi +echo "SCHEDULER_RECV_INTERVAL: $SCHEDULER_RECV_INTERVAL, CONC: $CONC, ISL: $ISL, OSL: $OSL" + +EVAL_CONTEXT_ARGS="" +if [ "${EVAL_ONLY}" = "true" ]; then + setup_eval_context + EVAL_CONTEXT_ARGS="--context-length $EVAL_MAX_MODEL_LEN" +fi +# Start GPU monitoring (power, temperature, clocks every second) +start_gpu_monitor + +set -x +PYTHONNOUSERSITE=1 python3 -m sglang.launch_server --model-path $MODEL --host 0.0.0.0 --port $PORT --trust-remote-code \ +--tensor-parallel-size=$TP --data-parallel-size=1 \ +--cuda-graph-max-bs 256 --max-running-requests 256 --mem-fraction-static 0.85 --kv-cache-dtype fp8_e4m3 \ +--chunked-prefill-size 16384 \ +--ep-size $EP_SIZE --quantization modelopt_fp4 --enable-flashinfer-allreduce-fusion --scheduler-recv-interval $SCHEDULER_RECV_INTERVAL \ +--enable-symm-mem --disable-radix-cache --attention-backend trtllm_mla --moe-runner-backend flashinfer_trtllm --stream-interval 10 $EVAL_CONTEXT_ARGS > $SERVER_LOG 2>&1 & + +SERVER_PID=$! + +# Wait for server to be ready +wait_for_server_ready --port "$PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" + +pip install -q datasets pandas + +run_benchmark_serving \ + --model "$MODEL" \ + --port "$PORT" \ + --backend vllm \ + --input-len "$ISL" \ + --output-len "$OSL" \ + --random-range-ratio "$RANDOM_RANGE_RATIO" \ + --num-prompts $((CONC * 10)) \ + --max-concurrency "$CONC" \ + --result-filename "$RESULT_FILENAME" \ + --result-dir /workspace/ + +# After throughput, run evaluation only if RUN_EVAL is true +if [ "${RUN_EVAL}" = "true" ]; then + run_eval --framework lm-eval --port "$PORT" + append_lm_eval_summary +fi + +# Stop GPU monitoring +stop_gpu_monitor +set +x diff --git a/perf-changelog.yaml b/perf-changelog.yaml index 3f081c240..b7449a187 100644 --- a/perf-changelog.yaml +++ b/perf-changelog.yaml @@ -1396,3 +1396,11 @@ - "Image: lmsysorg/sglang:v0.5.10.post1-cu130" - "TP=4, concurrency 4-256 for 1k1k and 8k1k" pr-link: https://github.com/SemiAnalysisAI/InferenceX/pull/1048 + +- config-keys: + - dsr1-fp4-b300-sglang + description: + - "Add DeepSeek-R1-0528 FP4 B300 SGLang benchmark (non-MTP)" + - "Image: lmsysorg/sglang:v0.5.10.post1-cu130" + - "Reuses existing B200 DSR1 FP4 SGLang recipe since the SGLang cookbook has no B300-specific recipe" + pr-link: https://github.com/SemiAnalysisAI/InferenceX/pull/XXXX From ae5e0bb281946155c568eaba62235e77985fa30f Mon Sep 17 00:00:00 2001 From: functionstackx <47992694+functionstackx@users.noreply.github.com> Date: Fri, 17 Apr 2026 01:56:57 -0400 Subject: [PATCH 2/4] Fill in PR link for dsr1-fp4-b300-sglang changelog entry Co-Authored-By: Claude Opus 4.7 (1M context) --- perf-changelog.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perf-changelog.yaml b/perf-changelog.yaml index b7449a187..9f4e72ff9 100644 --- a/perf-changelog.yaml +++ b/perf-changelog.yaml @@ -1403,4 +1403,4 @@ - "Add DeepSeek-R1-0528 FP4 B300 SGLang benchmark (non-MTP)" - "Image: lmsysorg/sglang:v0.5.10.post1-cu130" - "Reuses existing B200 DSR1 FP4 SGLang recipe since the SGLang cookbook has no B300-specific recipe" - pr-link: https://github.com/SemiAnalysisAI/InferenceX/pull/XXXX + pr-link: https://github.com/SemiAnalysisAI/InferenceX/pull/1049 From 8ef649873a1cd568667e36568b96671c4a74502f Mon Sep 17 00:00:00 2001 From: functionstackx <47992694+functionstackx@users.noreply.github.com> Date: Fri, 17 Apr 2026 01:59:27 -0400 Subject: [PATCH 3/4] Scope the cookbook note with "At the time of submission" Also mirror the note into nvidia-master.yaml and perf-changelog.yaml so future readers can see why the B200 recipe is being reused for B300. Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/configs/nvidia-master.yaml | 3 +++ benchmarks/single_node/dsr1_fp4_b300.sh | 6 +++--- perf-changelog.yaml | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/configs/nvidia-master.yaml b/.github/configs/nvidia-master.yaml index 5a4deb032..47d66aa2d 100644 --- a/.github/configs/nvidia-master.yaml +++ b/.github/configs/nvidia-master.yaml @@ -1669,6 +1669,9 @@ dsr1-fp4-b200-sglang: - { tp: 4, ep: 4, conc-start: 4, conc-end: 128 } - { tp: 8, ep: 8, conc-start: 4, conc-end: 16 } +# NOTE: At the time of submission, https://cookbook.sglang.io/autoregressive/DeepSeek/DeepSeek-R1 +# does not have a B300-specific recipe, so this config reuses the existing DSR1 FP4 +# B200 SGLang recipe as-is until B300-specific tuning is available. dsr1-fp4-b300-sglang: image: lmsysorg/sglang:v0.5.10.post1-cu130 model: nvidia/DeepSeek-R1-0528-FP4-V2 diff --git a/benchmarks/single_node/dsr1_fp4_b300.sh b/benchmarks/single_node/dsr1_fp4_b300.sh index 4530eda7d..7c26f3cba 100644 --- a/benchmarks/single_node/dsr1_fp4_b300.sh +++ b/benchmarks/single_node/dsr1_fp4_b300.sh @@ -1,8 +1,8 @@ #!/usr/bin/env bash -# NOTE: https://cookbook.sglang.io/autoregressive/DeepSeek/DeepSeek-R1 does not -# have a B300-specific recipe, so this script reuses the existing DSR1 FP4 B200 -# SGLang recipe as-is until B300-specific tuning is available. +# NOTE: At the time of submission, https://cookbook.sglang.io/autoregressive/DeepSeek/DeepSeek-R1 +# does not have a B300-specific recipe, so this script reuses the existing +# DSR1 FP4 B200 SGLang recipe as-is until B300-specific tuning is available. source "$(dirname "$0")/../benchmark_lib.sh" diff --git a/perf-changelog.yaml b/perf-changelog.yaml index 9f4e72ff9..75fae41e3 100644 --- a/perf-changelog.yaml +++ b/perf-changelog.yaml @@ -1402,5 +1402,5 @@ description: - "Add DeepSeek-R1-0528 FP4 B300 SGLang benchmark (non-MTP)" - "Image: lmsysorg/sglang:v0.5.10.post1-cu130" - - "Reuses existing B200 DSR1 FP4 SGLang recipe since the SGLang cookbook has no B300-specific recipe" + - "At the time of submission, https://cookbook.sglang.io/autoregressive/DeepSeek/DeepSeek-R1 does not have a B300-specific recipe, so this reuses the existing DSR1 FP4 B200 SGLang recipe as-is" pr-link: https://github.com/SemiAnalysisAI/InferenceX/pull/1049 From 20dbe26cbc995c06fdcd57fa3c20188c1ac3132c Mon Sep 17 00:00:00 2001 From: functionstackx <47992694+functionstackx@users.noreply.github.com> Date: Fri, 17 Apr 2026 02:18:34 -0400 Subject: [PATCH 4/4] Gate B300 MODEL path override to Qwen3.5-397B-A17B-FP8 only The /scratch/models override was unconditional, forcing every single-node B300 job to use a pre-staged local model path. Only Qwen3.5-397B-A17B-FP8 is pre-staged there; DSR1 and other models need to fall through so their benchmark scripts can `hf download` into the mounted cache. Co-Authored-By: Claude Opus 4.7 (1M context) --- runners/launch_b300-nv.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/runners/launch_b300-nv.sh b/runners/launch_b300-nv.sh index 3d863b54c..7c042b4f1 100644 --- a/runners/launch_b300-nv.sh +++ b/runners/launch_b300-nv.sh @@ -217,7 +217,12 @@ find . -name '.nfs*' -delete 2>/dev/null || true else HF_HUB_CACHE_MOUNT="/scratch/models" - export MODEL="/scratch/models/${MODEL#*/}" + # Qwen3.5-397B-A17B-FP8 is pre-staged under /scratch/models on the B300 cluster, + # so point MODEL at the local copy. Other models fall through and use `hf download` + # against the mounted cache from their benchmark script. + if [[ "$MODEL" == "Qwen/Qwen3.5-397B-A17B-FP8" ]]; then + export MODEL="/scratch/models/${MODEL#*/}" + fi SQUASH_FILE="/data/squash/$(echo "$IMAGE" | sed 's/[\/:@#]/_/g').sqsh" FRAMEWORK_SUFFIX=$([[ "$FRAMEWORK" == "trt" ]] && printf '_trt' || printf '') SPEC_SUFFIX=$([[ "$SPEC_DECODING" == "mtp" ]] && printf '_mtp' || printf '')