Skip to content

CUDA on one DGX Spark (GB10, 128 GB): Qwen3.8-Flash-Next NVFP4 with --parallel 4 --context 131072 — host swaps 22 GB from 3 concurrent streams although the startup estimate was 81 GiB #750

Closed

Description

@ThefloorMiner

Line: Python server 0.6.3 (the CUDA engine; we plan to re-measure on 0.6.6 before you look at this —
say the word if that changes anything for you).
Hardware: one NVIDIA DGX Spark (GB10, 128 GB unified memory), weights on local NVMe.
Checkpoint: local-inference-lab/Qwen3.8-Flash-Next-NVFP4 (106 GB), the card made for this box.
Command (production):

tensorfold serve <checkpoint-dir> --host 127.0.0.1 --port <port> \
  --name qwen3.8-flash-next --backend cuda --parallel 4 --context 131072 --no-update-check

What we see

  • One stream decodes ~28 tok/s, which is great.
  • The server's own startup line estimates 81.09 GiB within an 84.36 GiB budget
    (CUDA rank 0 startup estimate … native 262144, allocated prompt/reply window 131072, cache slots …)
    — i.e. it believes it fits, and on a 128 GB box "fits" should mean fits together with everything else.
  • From 3 concurrent streams the system starts swapping hard: free -h showed 111 GiB used of
    121 GiB
    and vmstat/swap showed ~22 GB swapped with 4 slots resident. At 3 streams a full
    agent session (several long contexts) thrashes; the four advertised slots are effectively 2.
  • We therefore run the box at 2 real streams and advertise 4. The gap between the startup estimate and
    the 3-stream reality is the whole issue: the estimate covers the engine's device side, but on GB10 the
    host page cache, the NVFP4 tables kept memory-mapped (PLE n-gram tables stay mmap'd — see the
    --ple-on-ssd startup refusal) and the KV windows all land in the same 128 GB pool.

What we'd like to know / suggest

  1. Is --parallel 4 --context 131072 on one 128 GB Spark a supported shape, or is the honest
    guidance --parallel 2 (or one --context reduction) there? A "what fits where" table for GB10
    (128 GB) per checkpoint class would make this answerable without burning nights — minimum NVIDIA card class & Apple RAM? (documentation request) #139 asked for a
    minimum-hardware table; this is the same question from the other end.
  2. Could admission control watch host memory too, not just the engine's device budget? On unified
    memory, refusing a third stream when available RAM drops under a floor is much kinder than swapping:
    our clients see a 60–80 s TTFT and a 3× decode slowdown instead of a clean rejection.
  3. A cheap start: the startup estimate line could print the host available memory alongside the
    device estimate
    (we had to free -h by hand to find the 9.7 GiB that were really left), and warn
    when parallel × context cannot plausibly coexist with it.

Close relative: #23 (closed) is the 2×Spark GLM-5.3-Flash OOM at context ≥ 65 536 — same unified-memory
theme, different family and single box. Happy to re-run the measurement matrix on 0.6.6 with your flags
of choice; we have the harness (a temperature-0 streaming probe measuring prefill, decode and 2-stream
aggregate per request).

Activity

  1. ashhart commented on Oct 14, 2026

    @ashhart
    Owner

    Hello @ThefloorMiner,

    Thank you for the memory report. Python CUDA 0.6.3, serving Qwen3.8-Flash-Next NVFP4 at --parallel 4 --context 131072, swaps about 22 GB at three streams. The startup estimate was 81.09 GiB within an 84.36 GiB budget.

    The Python line is frozen at v0.6.6. A remeasure on 0.6.6 stays on that line. Native 1.0.11 has no CUDA Flash Next server. The CUDA registry is Nemotron only (zig/src/native/cuda.zig:13), and the recipe points the port at #472 (docs/recipes/qwen3.8-flash-next.md:13). A measurement on that native server is the one we can act on.

    Thank you again.

  2. ashhart commented on Oct 15, 2026

    @ashhart
    Owner

    Thank you, @ThefloorMiner, for the swap measurements alongside the startup estimate.

    This was measured on the Python line at 0.6.3. That line is frozen at 0.6.6 and takes no more changes, so we are closing it here. Flash Next on the native CUDA server is in review in #869, and your shape goes into its gate: one GB10, NVFP4, --parallel 4 --context 131072. A shape the startup admits has to fit with host memory counted, or be refused at startup, never swap.

    Posted by Ash's AI Assistant Synthena

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions