Developer Runs Qwen3-0.6B in a 24 KB OS Written in Pure x86-64 Assembly
The asm-llm-os project shows that a minimal bare-metal OS can run a small AI model faster than llama.cpp on Linux.
A developer has fully abandoned Linux and run Qwen3-0.6B in a 24 KB operating system written in pure x86-64 assembly. According to the author, the model runs up to 54% faster than llama.cpp on Linux.
The Multiboot-compatible binary OS (asm-llm-os.elf) occupies 24,252 bytes. It was built from scratch without Linux, Windows, C, Rust, or libc. It boots in 74–94 ms, switches to 64-bit Long Mode, activates all CPU cores through APIC, maps 614 MiB of Q8_0 weights directly from physical memory, and starts an interactive chat with KV-cache, multi-turn dialogue, VGA, PS/2 keyboard, and serial port support.
Benchmark results against llama.cpp (Q8_0, -ngl 0) on an AMD EPYC 7642:
- 1 thread: 23.67 vs 16.63 tokens/s (+42%).
- 4 threads: 78.89 vs 51.08 tokens/s (+54%).
- 8 threads: 118.08 vs 80.79 tokens/s (+46%).
- 16 threads: 134.94 vs 103.03 tokens/s (+31%, peak 136.6).
On a diskless Proxmox VM with a 12-core 2014 Intel Xeon E5-2670 v3 and 2 GiB RAM, the system reaches the input prompt in under 5 seconds (kernel itself: 95 ms). The model runs directly from RAM, producing 78 tokens/s during generation and up to 111.5 tokens/s during input processing.
Results are bit-exact across thread counts. All 64 tokens generated with greedy decoding match PyTorch FP32 outputs (cosine similarity 0.99965).
A 14.7 KB ELF build for Linux (FAST_Q8=1, INT8×INT8, AVX2+F16C) also outperforms llama.cpp by 18–36% with 1 to 40 threads, while running directly on hardware with 2 MiB memory pages gives another 10% gain.
The OS source code, a tool for building a hybrid BIOS/UEFI ISO image, and instructions for configuring Proxmox without a disk are available under the MIT license.
Why it matters
AnalysisIt demonstrates how removing OS and runtime layers can reduce overhead and accelerate local AI inference on minimal or specialized hardware.
Discuss in community
Share your questions and insights with developers
Related in Ecosystem
Practical guides, core terminology, and agent skills
Local RSI arrives: Inkling-2-Mini self-improves in 10 minutes
Researchers tested whether Inkling-2-Mini from Thinking Machines can recursively improve itself on local GPUs without external supervision or labeled data.
Jev and System One AI: A Complete Practical Guide to the Decision Model from TypeSafe
A deep engineering breakdown of the flagship Jev model: System One architecture versus LLMs, Choice/Score/Noul primitives, request parallelism, confidence mathematics, video use cases, code, and an overview of local open-weight alternatives (Laya, GLiNER2.5, CLM-8B).
Part I. AI Agent Architecture: The Foundations
The eleven foundational building blocks of modern autonomous agents: model taxonomy, the agentic runtime loop, advanced prompting, distillation, skills architecture, memory systems, function calling, and FinOps.
Hetzner Bare-Metal vs Cloud Hyperscalers
A financial and technical analysis of infrastructure costs: why renting dedicated hardware in European data centers (Hetzner, OVH) is 5–10 times cheaper than AWS/GCP virtual machines for AI workloads.