Speed and memory
Measured numbers with the machine, the setup and the source for each one.
Every number here comes from one named machine on one date. Most are single runs. They show what was measured, not what you will get.
What every number carries
Each figure on this site has four things next to it: the model and its build, the machine, the date, and a link to the full record. A figure without those is not published here.
All runs below used one machine: an Apple M5 Max with 40 GPU cores and 128 GB of memory.
Against llama.cpp on the same GGUF file
Qwen3.8-27B UD-Q4_K_XL, 2026-09-09
| Prompt tokens | Runtime | Prefill |
|---|---|---|
| 6,219 | mlx-node | 810.5 |
| llama.cpp | 639.0 | |
| 18,754 | mlx-node | 778.2 |
| llama.cpp | 495.9 | |
| 32,488 | mlx-node | 546.4 |
| llama.cpp | 419.4 |
| Prompt tokens | mlx-node prefill | llama.cpp prefill | Ratio | mlx-node decode | llama.cpp decode | Ratio |
|---|---|---|---|---|---|---|
| 6,219 | 810.5 | 639.0 | 1.268x | 25.76 | 24.52 | 1.051x |
| 18,754 | 778.2 | 495.9 | 1.569x | 24.86 | 21.85 | 1.138x |
| 32,488 | 546.4 | 419.4 | 1.303x | 20.63 | 20.66 | 0.999x |
Tokens per second, median of three runs. Ratios are mlx-node divided by llama.cpp.
The runs were spread out. Observed prefill ranges, lowest to highest of the three runs:
| Prompt tokens | mlx-node | llama.cpp |
|---|---|---|
| 6,219 | 803.6 to 814.2 | 624.3 to 640.3 |
| 18,754 | 775.4 to 779.7 | 415.6 to 527.4 |
| 32,488 | 519.9 to 634.0 | 382.1 to 422.4 |
Conditions:
- macOS 26.6.2, on AC power.
- The same GGUF file and the same token ids in both runtimes.
- 512 new tokens per run, greedy sampling, no prompt cache reuse, no speculative decoding, one request at a time.
- Matched 2,048-token prefill chunks. These are matched settings, not each runtime's defaults.
- KV cache: BF16 in mlx-node, F16 in llama.cpp.
- llama.cpp: a release Metal build with full GPU offload and Flash Attention, at commit
a14dba686aaa. That commit is pinned; this is not a claim about the newest llama.cpp. - mlx-node at commit
c14e55847c8f. - A fresh process per runtime and prompt size, one warmup that is not counted, then three runs 60 seconds apart.
- The 32,488-token row allowed background desktop graphics, so it is not a peak figure.
- Load time, warmup and HTTP overhead are not in the rates. Outputs can differ between the runtimes; this does not compare answer quality.
Source: issue #142.
Gemma 4 12B IT QAT Q4_0, 2026-09-10
| Prompt tokens | Runtime | Prefill |
|---|---|---|
| 7,733 | mlx-node | 1,153.2 |
| llama.cpp | 1,252.0 | |
| 40,528 | mlx-node | 1,000.4 |
| llama.cpp | 740.9 | |
| 66,904 | mlx-node | 872.1 |
| llama.cpp | 526.5 |
| Prompt tokens | mlx-node prefill | llama.cpp prefill | Ratio | mlx-node decode | llama.cpp decode | Ratio |
|---|---|---|---|---|---|---|
| 7,733 | 1,153.2 | 1,252.0 | 0.921x | 50.53 | 48.70 | 1.038x |
| 40,528 | 1,000.4 | 740.9 | 1.350x | 39.84 | 35.29 | 1.129x |
| 66,904 | 872.1 | 526.5 | 1.656x | 34.05 | 28.80 | 1.182x |
mlx-node prefill is slower at the shortest prompt. Median of three runs, 256 new tokens, greedy, BF16 KV cache in both runtimes, 512-token prefill chunks, normal desktop apps running. This setup differs from the Qwen run, so the two tables do not rank the models.
Source: issue #142, Gemma 4 comment.
Muse-Glimmer 30B Q4_K_XL, 2026-09-11 and 12
Decode was within -3.8% to +0.8% of llama.cpp, for example 23.09 against 23.93 tok/s at 7,254 prompt tokens. Prefill was faster in all six matched comparisons. With its DFlash draft, output was 27% faster at 36K tokens and 57% slower at 60K. The report's own caveat applies: the desktop was in use, and the runs do not establish a stable ranking.
Source: issue #142, Muse-Glimmer comment.
Many chats on one model
Qwen3.8-27B UD-Q4_K_XL with its DFlash2 draft. Requests had the shape Portato sends: 20 tools, thinking on, temperature 1.0. One trial per case, 2026-11-17.
| Chats at once | Total output | Against one chat alone |
|---|---|---|
| 2 | 86.75 tok/s | 1.57x |
| 3 | 98.12 tok/s | 1.62x |
| 4 | 115.03 tok/s | 1.90x |
Read each ratio as the source gives it. The two-chat row is 86.75 against 55.38 tok/s for one chat in the same run. The three-chat and four-chat rows come from shorter 300-token replies and have their own one-chat baseline, so do not divide 115.03 by 55.38. The source also says tok/s carries sampling luck in this test.
A second run on 2026-11-18, with 8 tools, measured the ratio per step: the time N chats take one after the other, divided by the time of one N-chat step.
| Case | Per-step ratio |
|---|---|
| Two chats, 25K tokens of history | about 1.45x (1.41x to 1.66x) |
| Two chats, 150K tokens of history | 1.34x to 1.39x |
| Three chats | 1.65x to 1.69x |
| Four chats | 1.88x to 1.98x |
Sharing has a cost: in that run, a plain turn with no draft that ran beside draft turns went at 0.29x of its speed alone.
Source: concurrent inference notes.
Restart with the disk cache
Same model and machine, 2026-11-17, one trial. A 25,276-token conversation was reopened after a server restart. 25,264 tokens came back from the disk cache, and prefill took 146 ms. On the first start it took 36,255 ms.
Source: the same notes.
A 500 GB model on a 128 GB Mac
DeepSeek V4.1 Flash UD-Q4_K_XL is a 9-file GGUF of about 500 GB. Its experts are read from the internal SSD as tokens need them. 2026-10-28, greedy, 32 new tokens, each prompt cold in a fresh process, with other apps holding about 69 GiB.
| Prompt | Time to first token | Decode | Peak memory |
|---|---|---|---|
| 64 tokens | 7.89 s | 2.09 tok/s | 23.6 GiB |
| The next turn | 6.83 s | 2.49 tok/s | 23.6 GiB |
| 1K tokens | 26.45 s | 2.50 tok/s | 25.2 GiB |
| 8K tokens | 87.67 s | 2.23 tok/s | 29.7 GiB |
It is slow, and it runs. With about 20 to 24 GiB of expert cache, decode was 2.6 to 3.0 tok/s.
Source: model notes.
Smaller facts
- The DFlash2 draft for Qwen3.8-27B takes 3.58 GiB of memory, or 1.18 GiB after 4-bit quantization. Source: model notes.
- The privacy filter ran on an M3 Max with 36 GB. In bf16 it ran at 21,219 tokens per second on 512-token inputs and 18,768 on 2K inputs; the other modes were within 17,888 to 20,807. Peak memory was 1.40 GB in the 4-bit modes against 4.30 GB in bf16. The input was synthetic and the date was not recorded. Source: privacy filter notes.
What we do not publish
- CUDA speeds. The figures in the repo predate the current CUDA kernels.
- Numbers that exist only in pull request text, from one run on one prompt.
- A comparison with mlx-lm. None has been measured and recorded.
- Old ratios for a decode path that has since been removed.