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.

Merge branch 'main' into feat/uefi-framebuffer-console

Alexey Fateev53afea26c9ee
diff --cc Makefile
index a2ae3b8,38dd2fb..f16b791
--- a/Makefile
+++ b/Makefile
@@@ -140,15 -140,13 +141,15 @@@ check: $(TARGET
$(OS_BUILD):
mkdir -p $(OS_BUILD)
- $(OS_BUILD)/%.o: $(P2_DIR)/%.asm $(P2_DIR)/os_constants.inc $(SHARED_DIR)/constants.inc $(FAST_Q8_STAMP) | $(OS_BUILD)
+ $(OS_BUILD)/%.o: $(P2_DIR)/%.asm $(P2_DIR)/os_constants.inc $(SHARED_DIR)/constants.inc $(SHARED_DIR)/isa.inc $(FAST_Q8_STAMP) | $(OS_BUILD)
$(NASM) $(OS_AFLAGS) $< -o $@
+$(OS_BUILD)/fbcon.o: $(P2_DIR)/font8x8.inc
+
- $(OS_BUILD)/math.o: $(SHARED_DIR)/math.asm | $(OS_BUILD)
+ $(OS_BUILD)/math.o: $(SHARED_DIR)/math.asm $(SHARED_DIR)/isa.inc $(FAST_Q8_STAMP) | $(OS_BUILD)
$(NASM) $(OS_AFLAGS) $< -o $@
- $(OS_BUILD)/matmul.o: $(SHARED_DIR)/matmul.asm $(FAST_Q8_STAMP) | $(OS_BUILD)
+ $(OS_BUILD)/matmul.o: $(SHARED_DIR)/matmul.asm $(SHARED_DIR)/isa.inc $(FAST_Q8_STAMP) | $(OS_BUILD)
$(NASM) $(OS_AFLAGS) $< -o $@
$(OS_BUILD)/tokenizer.o: $(SHARED_DIR)/tokenizer.asm $(SHARED_DIR)/constants.inc | $(OS_BUILD)
diff --cc README.md
index 5457d39,4efb683..6f5f541
--- a/README.md
+++ b/README.md
@@@ -100,7 -100,8 +100,8 @@@ make all # Builds Phase 1 (asm-llm, t
```
- **01 · Qwen3 Inference (`15.1 KB`):** `python3 scripts/export_weights.py --model-dir models/qwen3-0.6b-bf16 --out models/qwen3-0.6b-q8_0.asmbin --scale-dtype fp16 && ./build/asm-llm -m models/qwen3-0.6b-q8_0.asmbin --chat -t 16` → [01-qwen3-inference/README.md](01-qwen3-inference/README.md)
-- **02 · Bare-Metal OS (`25.4 KB`):** `make os-run MODEL=models/qwen3-0.6b-q8_0.asmbin SMP=16` *(or `make os-iso` for BIOS+UEFI ISO)* → [02-baremetal-os/README.md](02-baremetal-os/README.md)
- - **USB boot:** there is no prebuilt ISO to download — build it with `make os-iso MODEL=models/qwen3-0.6b-q8_0.asmbin` (needs the `grub-pc-bin`, `grub-efi-amd64-bin`, `mtools`, `xorriso` packages from the 02 README). It produces a hybrid BIOS+UEFI ISO at `build/asm-llm-os.iso` (~661 MiB); write that file to a USB stick (e.g. `dd`, Rufus, or balenaEtcher) and boot the machine from USB. Full steps: `02-baremetal-os/README.md`, Option B.
+- **02 · Bare-Metal OS (`27.2 KB`):** `make os-run MODEL=models/qwen3-0.6b-q8_0.asmbin SMP=16` *(or `make os-iso` for BIOS+UEFI ISO)* → [02-baremetal-os/README.md](02-baremetal-os/README.md)
++ - **USB boot:** there is no prebuilt ISO to download - build it with `make os-iso MODEL=models/qwen3-0.6b-q8_0.asmbin` (needs the `grub-pc-bin`, `grub-efi-amd64-bin`, `mtools`, `xorriso` packages from the 02 README). It produces a hybrid BIOS+UEFI ISO at `build/asm-llm-os.iso` (~661 MiB); write that file to a USB stick (e.g. `dd`, Rufus, or balenaEtcher) and boot the machine from USB. Full steps: `02-baremetal-os/README.md`, Option B.
- **03 · Mini-GPT Trainer (`33.9 KB`):** `./build/asm-gpt-train --data data/tinyshakespeare.txt --steps 400 --seq 128 -t 16 --save checkpoints/shakespeare.ckpt` → [03-minigpt-train/README.md](03-minigpt-train/README.md)
- **04 · Ring `-1` Kernel Surgeon (`75.4 KB`):** `cd 04-ring1-kernel-surgeon && make hv && python3 verifier/kvm_verifier.py --selftest` → [04-ring1-kernel-surgeon/README.md](04-ring1-kernel-surgeon/README.md)
- **05 · Linux `6.12` eBPF LSM (`21.3 KB`):** `cd 05-ebpf-jev && bash testbed/build.sh && testbed/run_vm.sh verify` → [05-ebpf-jev/README.md](05-ebpf-jev/README.md)