A 24 KB Assembly OS Boots Straight Into Qwen3 in 74 ms, and Out-Decodes llama.cpp on Linux Developer alesha-pro published llm.asm on GitHub under the MIT license, a 24,252-byte bare-metal x86-64 assembly OS that boots through GRUB into Qwen3-0.6B and reaches a chat prompt in 74 to 94 ms. On an AMD EPYC 7642 with Q8_0 weights and 64 generated tokens over three runs, the bare-metal OS reached 78.9 tokens per second at four threads versus llama.cpp's 51.1 on Linux, the roughly 54 percent gain Tom's Hardware reported, while the Linux build of llm.asm beat llama.cpp by 18 to 36 percent at every thread count. The README cautions that llama.cpp batches prompts while llm.asm only runs token-by-token decode, and the developer reports 64 of 64 greedy tokens matching a PyTorch FP32 reference at 0.99965 cosine similarity. A developer has written a bootable operating system in pure x86-64 assembly whose only job is running Qwen3-0.6B. The whole OS is 24 KB, it reaches a chat prompt in under 100 ms, and on the same EPYC server it decodes tokens faster than llama.cpp running on Linux. There is no Linux kernel underneath it, no libc, and not a single line of C. The project is called llm.asm https://github.com/alesha-pro/llm.asm , published on GitHub under the handle alesha-pro and released under the MIT license. It is actually three projects in one repository: a Qwen3 inference engine that runs as a normal Linux program, a mini-GPT trainer, and the part that got everyone’s attention, a bare-metal OS https://github.com/alesha-pro/llm.asm/tree/main/02-baremetal-os that boots through GRUB and drops you straight into a conversation with the model. The numbers are almost silly. The OS image is 24,252 bytes. The quantized Qwen3-0.6B weights it loads are about 614 MiB, so the code that runs the model is a rounding error next to the model itself. The README reports 74 to 94 ms from boot to the chat prompt. What is actually in 24 KB More than you would expect. The OS switches the CPU into 64-bit long mode, brings up every core through ACPI and the APIC, and spreads the matrix math across them. It prints to the old 80×25 VGA text console, reads a PS/2 keyboard, and mirrors everything to a serial port. The chat keeps its KV cache between turns, and there are commands to clear the context, toggle Qwen3’s thinking mode, and run a built-in benchmark. What it does not have is just as telling. There is no storage driver, no network stack and no GPU support. The model weights arrive as a Multiboot module, which means the bootloader drops them into RAM before the OS even starts. Everything runs on the CPU, and it needs AVX2, FMA and F16C, so anything from Intel Haswell or AMD Excavator onward. The weights use Q8 0 quantization, converted from the official bf16 checkpoint by a Python export script, which is the only non-assembly code in the pipeline. Faster than llama.cpp, with an asterisk The developer benchmarked everything on an AMD EPYC 7642 with Qwen3-0.6B at Q8 0, 64 generated tokens, averaged over three runs, with llama.cpp forced onto the CPU for a fair fight. The Linux build of llm.asm already wins at every thread count, by roughly 18 to 36 percent. At four threads it does 69.2 tokens per second against llama.cpp’s 51.1. The bare-metal OS, running under KVM, pushes further: 78.9 tokens per second at four threads and a peak of about 135 at sixteen. That four-thread result is where the “up to 54 percent faster” figure reported by Tom’s Hardware https://www.tomshardware.com/tech-industry/artificial-intelligence/ai-enthusiast-deletes-linux-to-run-qwen3-on-a-24kb-pure-x86-64-assembly-os-28-000-times-smaller-than-model-system-boots-in-74-milliseconds-runs-llms-up-to-54-percent-faster comes from. It compares the bare-metal OS against llama.cpp on Linux, so part of the gain is the assembly code and part is the missing operating system. The README itself flags the main caveat. llama.cpp processes prompts in batches, while llm.asm only runs token-by-token decode, so the comparison covers generation speed and nothing else. This is also a 0.6B-parameter model. Larger models lean harder on memory bandwidth, where hand-tuned instructions buy you far less. On accuracy, the developer reports 64 out of 64 greedy tokens matching a PyTorch FP32 reference, with a cosine similarity of 0.99965. Why it matters Nobody is going to replace their inference server with a hobby OS that cannot read a disk. But llm.asm is a neat demonstration of how much overhead sits between a small model and the silicon running it. It is also a reminder that the 2026 CPU inference scene has plenty of headroom left in plain old SIMD code. If you have a spare box with a Haswell or newer chip, the repository includes a script that builds a bootable ISO for both BIOS and UEFI. Or you can just run it in QEMU and watch an LLM come up faster than your monitor wakes from standby.