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.
Include two vCPUs in the Phase 2 SMP sweep
alteralto563df8e3f875
diff --git a/scripts/verify_os.py b/scripts/verify_os.pyindex dd37064..2165cf7 100755--- a/scripts/verify_os.py+++ b/scripts/verify_os.py@@ -458,7 +458,9 @@ def main():log("=" * 78)# 1. Exact Parity vs Phase 1 across 5 diverse prompts (EN, RU UTF-8, Math, Think)- log("\n=== 1. EXACT PARITY VS PHASE 1 (LINUX build/asm-llm vs BARE-METAL KVM 16 vCPU) ===")+ p1_threads = min(32, args.max_threads)+ os_smp = min(16, args.max_threads)+ log(f"\n=== 1. EXACT PARITY VS PHASE 1 (LINUX {p1_threads} threads vs BARE-METAL KVM {os_smp} vCPU) ===")prompts = [("Phase1-Cache-64", "Explain the difference between L1, L2, and L3 CPU caches and why cache locality matters.", 64, False),("EN-Concise-64", "Explain how a CPU cache works in 3 concise sentences.", 64, False),@@ -467,8 +469,6 @@ def main():("Think-Mode-192", "What is 17 * 23?", 192, True),]all_parity_ok = True- p1_threads = min(32, args.max_threads)- os_smp = min(16, args.max_threads)for name, prompt, max_tok, think in prompts:p1 = run_phase1(args.model, prompt, max_tok, think=think, threads=p1_threads)os_res = run_os_batch(args.model, prompt, max_tok, smp=os_smp, think=think, print_tokens=True)@@ -491,15 +491,15 @@ def main():preview = os_res["text"].replace("\n", " / ")[:110]log(f" Output: {preview}")- # 2. SMP Determinism & KVM Scaling Benchmark (1, 4, 8, 16, 24, 32 vCPUs)- log("\n=== 2. BARE-METAL SMP SCALING & DETERMINISM BENCHMARK (QEMU KVM, AMD EPYC 7642) ===")+ # 2. SMP Determinism & KVM Scaling Benchmark+ log("\n=== 2. BARE-METAL SMP SCALING & DETERMINISM BENCHMARK (QEMU KVM) ===")bench_prompt = "Explain the difference between L1, L2, and L3 CPU caches and why cache locality matters."ref_p1 = run_phase1(args.model, bench_prompt, 64, think=False, threads=p1_threads)log(f"Prompt: {bench_prompt!r} (34 prompt tok, 64 gen tok, greedy)")log(f"{'vCPUs':>5s} | {'Online':>6s} | {'Boot(ms)':>8s} | {'Boot->1st':>9s} | {'Prefill ms':>10s} | {'Prefill t/s':>11s} | {'Decode ms':>9s} | {'Decode t/s':>10s} | {'QEMU Wall':>9s} | Determinism")log("-" * 116)smp_all_ok = True- for smp in [s for s in (1, 4, 8, 16, 24, 32) if s <= args.max_threads]:+ for smp in [s for s in (1, 2, 4, 8, 16, 24, 32) if s <= args.max_threads]:r = run_os_batch(args.model, bench_prompt, 64, smp=smp, think=False, print_tokens=True, timeout_s=120)online_ok = (r["smp_online"] == smp)det_ok = (r["gen_tokens"] == ref_p1["gen_tokens"]) and (r["text"] == ref_p1["text"])