DeepSeek V4.1 Flash on 2× DGX Spark: 19 or 91 tok/s?
DeepSeek V4.1 Flash on two DGX Sparks: llama.cpp RPC gives 19 tok/s, the TensorFold recipe 76–91 tok/s. My numbers and the pitfalls of both setups.
This article in other languages:Polski
In this article
I ran DeepSeek V4.1 Flash on two DGX Sparks in two ways: through llama.cpp RPC and through the dedicated TensorFold recipe. Both servers got the same set of tests. llama.cpp generates about 19 tok/s, TensorFold between 76 and 91 tok/s, and it reads the prompt 7–8 times faster.
Why two Sparks?
DeepSeek-V4.1-Flash-1017 doesn’t fit on one. I have two DGX Sparks (GB10, 128 GB of unified memory each) connected directly with a 200G QSFP cable, so the model had to be split across both boxes. (I covered where sizes like this come from in how much VRAM you need for an LLM.)
The model is the so-called “abliterated” version, in both setups. I tried two ways of splitting it and measured each with the same script, from the client side, with streaming on.
How do the two setups differ?
| A: llama.cpp RPC | B: TensorFold recipe | |
|---|---|---|
| Quantization | GGUF UD-IQ1_S (~122 GB of weights + 110 GB Engram table) | EXL3 2.9 bpw + abliteration overlay (ABLIT=1) |
| Split | by layers: llama-server on the first Spark, ggml-rpc-server on the second (-ts 45,55) |
tensor-parallel TP=2, one rank per Spark, RDMA over both CX7 lanes |
| Engram table (110 GB) | read lazily from NVMe (--lazy-mode on) |
on the local disk of both machines |
| Context tested | 32K tokens | 256K configured (supports 1M) |
| Extras | none | DSpark speculative drafts, image input, 4 streams |
| Launch | compile llama.cpp and run one command | ./start.sh: builds the image, downloads ~400 GB, writes weight files for each rank |
The gap in effort is considerable. With llama.cpp you build the project and start it. The TensorFold recipe worked for about 2 hours the first time, but after that the model loads in 35 seconds.
DeepSeek V4.1 Flash on DGX Spark: test results
| Test | A: llama.cpp IQ1_S | B: TensorFold EXL3 2.9 | B vs A |
|---|---|---|---|
| Generation, prose (1,200 tokens) | 19.6 tok/s | 76.0 tok/s | 3.9× |
| Generation, code | 19.0 tok/s | 90.8 tok/s | 4.8× |
| Time to first token (short prompt) | 0.4–1.4 s | 0.23–0.27 s | |
| Prefill, 7K tokens | 297 tok/s (24.3 s) | 2,087 tok/s (3.5 s) | 7× |
| Prefill, 16K tokens | 297 tok/s (54.8 s) | 2,250 tok/s (7.2 s) | 7.6× |
| Prefill, 29K tokens | 290 tok/s (100.8 s) | 2,251 tok/s (13.0 s) | 7.8× |
| Prompt cache (12K prefix, second question) | 43.6 s → 0.34 s | 8.2 s → 0.94 s | |
| 4 requests at once, total | 18.8 tok/s (queued, 1 slot) | 130.5 tok/s (~34 per stream) | 6.9× |
| Needle in a 27.5K-token prompt | found (94 s) | found (12 s) | |
| Needle in a 216K-token prompt | n/a (32K context) | found, 106 s in total |
Prefill, meaning the time spent reading the prompt, is where you feel it most. At 29K tokens llama.cpp needs over a minute and a half before it starts answering at all; TensorFold takes 13 seconds.
The prompt cache works well in both engines. A second question against the same 12K-token prefix comes back in a fraction of a second, and here llama.cpp happens to be the faster one (0.34 s against 0.94 s).
Concurrency is a separate story. My llama.cpp server has a single slot, so four requests wait in a queue and together produce the same ~19 tok/s. TensorFold serves four streams at once, each at around 34 tok/s.
And then context. I could only run the 216K-token needle test on TensorFold, because I tested llama.cpp with a 32K window. The model found the needle, and the whole answer took 106 seconds.
What about answer quality?
In my tests both sides came out the same:
| Test | A: llama.cpp | B: TensorFold |
|---|---|---|
| 8 checkable questions (math, the letter “r” in “strawberry”, 9.11 or 9.9, dates, a derivative…) | 8/8 | 8/8 |
| Tool calls (weather with an enum argument, email, “don’t use the tool”) | 3/3 | 3/3 |
| Answer in Polish | fluent | fluent |
Read this with caution, though. The llama.cpp quantization is about 1.6 bits per weight, TensorFold’s is 2.9 bits, and my set of eight questions is too easy to tell the two apart. The quality headroom that 2.9 bpw gives doesn’t show up in these numbers.
I checked refusals too. Across five harmless but borderline requests, neither version refused once. Two answers did come back empty at a 1,500-token limit, because the model, with thinking enabled, ran out of room before it finished reasoning. With the limit raised, TensorFold answered one of those questions in full (1.9K tokens), while on the other the model was still thinking after 6,000 tokens. So for ordinary chat, turn thinking off or set a large max_tokens.
What should you watch for with llama.cpp RPC?
- Once an RPC device is attached, the default load mode silently disables mmap. The Engram table (110 GB) then lands in RAM, and on my setup the OOM killer took down the first Spark. You have to pass
--load-mode mmap --lazy-mode onexplicitly. - The RPC server has a new name: it is now
ggml-rpc-server. - Splitting by layers means the machines take turns, so at any given moment you get the throughput of a single box. Hence the ~19 tok/s.
What should you watch for with the TensorFold recipe?
- The recipe needs 112 GiB of free memory on each Spark, so nothing else large will run alongside it. With the model loaded I had about 9–10 GiB left per machine (the memguard built into the recipe keeps an eye on that).
- Network and hardware have to be prepared: both twin CX7 interfaces addressed (
enp1s0f0np0andenP2p1s0f0np0), the same GPU clock on both machines (nvidia-smi -lgc 0,2200), an NFS export of the HF cache from the head node to the worker, and your user in thedockergroup. - The
hfcommand must be on PATH for non-interactive ssh too, otherwise the prepare script stops. - The abliteration overlay is a gated HF repository, so you accept the terms first. It rewrites the shards into a separate directory and needs extra space: ~231 GB on the head node and ~99 GB of rank cache on the worker.
- Total disk comes to ~620 GB on the head node and ~290 GB on the worker.
The list is longer than for llama.cpp, but you only do all of this once ;)
Which setup should you pick?
In my view, if you have two Sparks and want DeepSeek V4.1 Flash, the TensorFold recipe is the one to pick. It generates 4–5 times faster, reads the prompt 7–8 times faster, handles several requests at once, gives you a 256K–1M token context and image input, and on top of that uses a much better quantization (2.9 bpw instead of ~1.6 bpw).
llama.cpp RPC remains the “works with any GGUF in 10 minutes” option. But at 19 tok/s and ~300 tok/s of prefill, a coding agent with a 20K-token system prompt waits about 70 seconds for the first token in every new session. With TensorFold it’s about 9 seconds.
(Hardware: 2× DGX Spark (GB10), DGX OS, a direct QSFP RoCE link on two lanes, MTU 9000. Both servers had an API key enabled, a single user and nothing else running in the background.)
I wrote about the regular V4.1 Flash in an agent harness in DeepSeek for free in OpenCode, and about where to start on an ordinary computer in the guide on how to run AI locally.