Skip to content

Qwen3-0.6B inference (12 KB), bare-metal bootable OS (22 KB), and from-scratch Mini-GPT trainer with live Braille TUI (32 KB) in 100% pure x86-64 NASM assembly. Zero C, zero libc, zero dependencies.

docs(01): add huge-pages tmpfs tip from #66

Asad Faizeeb107886398f4
diff --git a/01-qwen3-inference/README.md b/01-qwen3-inference/README.md
index a2b92e3..1a2e765 100644
--- a/01-qwen3-inference/README.md
+++ b/01-qwen3-inference/README.md
@@ -120,6 +120,17 @@ There is no dynamic section in this file.
> a full recompute of the same tokens. Use `/clear` to start a fresh
> history when the context fills up.
+**Tip — run the model from huge pages (#66):** Phase 2's speed edge over Phase 1 comes largely from its 2 MiB page mapping. On Linux you can get most of that back with no code change by putting the model file on a huge-page tmpfs and pinning the threads:
+
+```bash
+mount -t tmpfs -o huge=always,size=1g tmpfs /mnt/llmhuge
+cp models/qwen3-0.6b-q8_0.asmbin /mnt/llmhuge/
+taskset -c 0-15 ./build/asm-llm -m /mnt/llmhuge/qwen3-0.6b-q8_0.asmbin \
+ -p "..." -n 128 -t 16
+```
+
+Reported in #66 on a Xeon Gold 5418Y (single-DIMM, memory-bandwidth bound): huge pages alone were worth ~6–9% at 4–16 threads, bringing Phase 1 within ~1% of the bare-metal OS on that machine. Results will vary with memory channels and NUMA layout; output was identical in every configuration.
+
---
## CLI Reference