All News | Boards | Chips | Devices | Software | LinuxDevices.com Archive | About | Contact | Subscribe
Follow LinuxGizmos:
Twitter Facebook Pinterest RSS feed
*   get email updates   *

Raspberry Pi 5 cluster runs Qwen3-30B-A3B at 15 tokens/s on CPU

Oct 6, 2026 — by Giorgio Mendoza 3,450 views

Hellomatik has published a study and a modified distributed-llama implementation for running the Qwen3-30B-A3B language model across four Raspberry Pi 5 boards. Using only the boards’ Arm Cortex-A76 CPUs, the cluster reached a reported decode throughput of 15.143 tokens per second, without GPU or NPU acceleration or CPU overclocking.

The setup uses four Raspberry Pi 5 boards with 16GB of LPDDR4X memory each. Every node is based on the Broadcom BCM2712 with four Arm Cortex-A76 cores at 2.4GHz, while storage is provided through NVMe SSDs and communication between nodes uses Gigabit Ethernet. The system runs Debian 13 with a 6.12.75 aarch64 kernel.

— ADVERTISEMENT —



Completed Raspberry Pi 5 cluster
(click image to enlarge)

Qwen3-30B-A3B is a Mixture-of-Experts model with around 30 billion total parameters, but only about 3 billion are active for each generated token. Hellomatik used a Q40-quantized version with 128 experts and a top-k value of eight, reducing the amount of memory traffic required during inference compared with a similarly sized dense model.

Across 20 benchmark runs, Hellomatik measured an average decode throughput of 15.143 tokens/s, compared with 13.15 tokens/s for the unmodified distributed-llama implementation on identical hardware, representing a 15.2% improvement. The result also exceeds the previously published 13.04 tokens/s benchmark by 16.1%, while sustained end-to-end throughput, including prompt processing, reached 14.449 tokens/s.


Qwen3-30B-A3B decode throughput comparison
(click image to enlarge)

The 15.143 tokens/s result has not yet been independently reproduced, according to Hellomatik. The company says output correctness was checked by comparing SHA-256 hashes of generated token IDs at temperature zero, while the benchmark used the same command as a previously published distributed-llama result.

The cluster runs one Raspberry Pi as the root coordinator and three as worker nodes over a 1Gbps network. The distributed-llama uses tensor parallelism, dividing model processing across the four systems and synchronizing data between nodes during each transformer layer.


Four Raspberry Pi 5 boards with PoE+ HATs and NVMe drives
(click image to enlarge)

Much of the performance gain came from software and system-level tuning rather than higher CPU frequencies. Hellomatik applied twelve source-level changes to distributed-llama, including fixes for memory alignment and buffering, kernel fusion and larger TCP buffers, alongside operating-system and networking adjustments. The system was also configured with the performance CPU governor, low swappiness, NVMe tuning and adjusted TCP parameters.

One optimization involved compiling specifically for the Cortex-A76 architecture to enable Arm NEON dot-product instructions. The researchers also enabled SDRAM_BANKLOW=1 in the Raspberry Pi bootloader configuration, reporting an increase in memory read bandwidth from 8.3GB/s to 12.5GB/s per board.


Raspberry Pi 5 cluster inference optimization results
(click image to enlarge)

The optimization process included several changes that produced little or negative improvement. For example, the researchers found that removing manual software-prefetch instructions from a matrix-multiplication loop improved performance because the Cortex-A76 hardware prefetcher handled the access pattern more effectively. A single-pass SiLU multiplication fusion also reduced memory operations and provided an additional measured improvement.

ARM performance-monitoring counters showed approximately 49% backend-stalled CPU cycles and around 11.4GB/s of sustained DRAM traffic per node, compared with an estimated 17GB/s memory-bandwidth ceiling. The researchers therefore describe the final configuration as reaching the Raspberry Pi 5’s “memory wall.”


Qwen3-30B-A3B per-token processing breakdown
(click image to enlarge)

Hellomatik also evaluated alternative approaches including EXO, prima.cpp and llama.cpp RPC. According to the paper, EXO depends on Apple’s MLX framework, prima.cpp failed during topology initialization on the Pi 5 setup, and llama.cpp RPC showed substantially lower distributed performance.

A limitation of the setup is prompt-processing speed. The study measured prefill performance above 15 tokens/s for prompts up to around 2,000 tokens, but estimated that very large prompts, such as 20,000-token agent contexts, could require more than 20 minutes to process.

Further Information

Hellomatik has published its modified distributed-llama repository, including source-code changes, benchmark scripts and configuration files needed to reproduce the results.

The accompanying research paper and benchmark data provide additional performance measurements and technical details.

(advertise here)


PLEASE COMMENT BELOW

One response to “Raspberry Pi 5 cluster runs Qwen3-30B-A3B at 15 tokens/s on CPU”

  1. 7wick says:

    Using a old laptop/pc or maybe a few mobile phones laying around would be better in performance and cost too, but i dont see any application that can be used for this orchestration

Please comment here...