
Qwenputer: 32-bit RISC-V CPU Compiled Into Qwen 3.5 4B Weights
Divyansh Agrawal's Qwenputer compiles a 32-bit RISC-V CPU into Qwen 3.5 4B's weights, using DeltaNet state as RAM to run C, MicroPython and DOOM with 18 million error-free instructions.
- By
- Nathan Brooks
- Filed
- Channel
- AI & Compute
- Read
- 3 min read
An AI engineer has compiled a 32-bit RISC-V CPU directly into the weights of a stock Qwen 3.5 4B large language model and run DOOM on it. Slowly, but it runs. The project, called Qwenputer, is the work of Divyansh Agrawal, and it treats a modern LLM as a host for an actual software-defined processor rather than a chatbot with tool access.
The core of the trick is memory. Agrawal used Qwen's Gated DeltaNet (GDN) state as RAM, a move he calls "a pretty neat trick." He concedes the idea of fast weights serving as RAM is not original. Applying it to Qwen 3.5 in this fashion, however, appears to be a first.
How do you build a CPU without training it?
The implementation departs sharply from how LLMs are normally made. The RISC-V CPU "is 11 transformer layers in front of Qwen's own, and none of their weights are learned: a compiler computes every one," the project explains. There is no fine-tuning, no gradient descent, no training run. A compiler emits the weights, the model executes them.
The results are unusually verifiable for an LLM stunt. Agrawal states that Qwenputer's built-in CPU "passes the official riscv-tests, its programs match qemu, and it has run 18 million instructions free-running without a single error." Eighteen million faultless instructions is a claim most hardware emulators would be content to make.
The practical payoff is exactness. Qwen sends instructions to the CPU and reads results back with no external tool calls and no runtime, which sidesteps the arithmetic sloppiness that afflicts many language models. Users can also run C and MicroPython code on the embedded processor. And, inevitably, they can run DOOM.
What else is inside?
A CPU needs storage, so Agrawal added a filesystem. He describes the extension as relatively trivial once RAM exists. The filesystem also lives in the DeltaNet state and offers:
- 1,024 storage slots
- capacity for up to 512 files
- persistence, provided the user saves the state at the end of a conversation with the model
That last point deserves emphasis. Files written inside an LLM's internal state survive the session if the conversation state is saved. The model has, in effect, a persistent disk made of activations.
What does it cost to run?
The resources required are not trivial. Qwenputer roughly doubles the size of the underlying Qwen 3.5 4B model to almost 19GB. Agrawal recommends a workstation with 24GB of VRAM or more to test the current version. That places a comfortable margin above the base model's needs, though well within reach of a single modern workstation GPU.
Agrawal is working to streamline coding on the system and to make it run faster. Speed, judging by DOOM's crawl, is the obvious next frontier.
Is there a commercial angle?
Probably not yet, and the source does not pretend otherwise. Agrawal built Qwenputer primarily to explore what is possible rather than to solve a specific problem. Still, the experiment raises genuine questions about whether transformer weights can host deterministic computation, exact arithmetic and persistent storage without any external runtime.
For those inclined to test such questions themselves, the project is not locked away. The code is MIT-licensed on GitHub, and the model itself is available on Hugging Face. Qwenputer is roughly the weight of a small game console and about as fast as one submerged in syrup. Whether that ratio improves may determine whether the idea graduates from curiosity to tool.
Source: Tom's Hardware
More from Nathan Brooks
Show full bio
Senior reporter covering people, launches and day-to-day practice in Semiconductors, chip manufacturing, hardware, AI compute at Chip Dispatch.
759 articles
Related articles
tenstorrent-raises-1-5-billion-to-scale-risc-v-ai-servers-869ce9b0
Tenstorrent Raises $1.5 Billion to Scale RISC-V AI Servers
china-s-lingsheng-takes-supercomputing-crown-at-2-74-exaflops-peak-a751151c
China's LingSheng Takes Supercomputing Crown at 2.74 Exaflops Peak
deepseek-open-sources-ascend-software-stack-targets-cuda-moat-f6e44544
DeepSeek Open-Sources Ascend Software Stack, Targets CUDA Moat
huawei-and-deepseek-team-up-on-ai-chip-design-to-challenge-nvidia-63da2d86
Huawei and DeepSeek Team Up on AI Chip Design to Challenge Nvidia



