A Linux ABI-compatible kernel
written from scratch in Rust
Every subsystem of Rux โ scheduler, memory management, ext4, binder, the network stack and the verification framework โ was implemented by AI agents; humans set goals, review and merge. Unmodified Ubuntu 22.04 boots to a GNOME Shell desktop (stability-verified 5/5 boots), unmodified Ubuntu 24.04 reaches the graphical targets through systemd 255 with serial login, and unmodified OpenHarmony boots all 135+ services โ no patches, no rebuilds, no configuration changes.
Verified with unmodified distributions
Compatibility is verified directly against unmodified distribution images and upstream userspace โ no porting-layer adapters. All screenshots are native framebuffer/serial captures from the Rux kernel.
One kernel tree, three architectures
x86_64 is the first-priority development and test platform (KVM near-native acceleration; all functional/performance/LTP testing runs there); riscv64 and aarch64 are kept as three-architecture build + regression gates.
| Architecture | QEMU machine | Accel | Userspace | Status |
|---|---|---|---|---|
| x86_64 | q35 | KVM (primary) | Ubuntu 22.04 + 24.04 (glibc) | 22.04 GNOME desktop 5/5 ยท 24.04 graphical targets + serial login ยท main LTP/perf test platform |
| riscv64 | virt | TCG (MTTCG) | Ubuntu 22.04 / musl minimal rootfs | Desktop + kernel suite 1584/1584 |
| aarch64 | virt (gic-version=3) | TCG | Interactive shell | shell / signals / kernel suite green |
The ABI is the contract; the internals are a clean-room design
Externally: syscall numbers and semantics, ELF/auxv, futex, the procfs layout โ down to the uname strings glibc's loader keys on โ all match Linux. Internally: free of historical baggage, better designs in Rust โ every internal divergence is registered with compatibility evidence.
๐Compatibility as the constitution
POSIX and the Linux kernel ABI are the supreme constraints: LTP families pass family by family; distribution userspace runs unmodified.
๐ก๏ธRust safety, with a ledger
All-Rust kernel (no_std). All 33 memory-corruption defects in history are individually filed: 23 in audited unsafe/assembly, 10 in safe code (all ownership/lock-protocol classes safe Rust does not type-check today); pointer-expression classes (OOB, wild pointers, format strings) are zero in safe code.
๐คParallel AI engineering
Multiple agents develop in parallel: one worktree and branch per task, the main session reviews and merges. Several merges per day, full regression protection.
โกPerformance is a gate
Every merge is reviewed for both function and performance: three gate tiers + six guarded domains (memory/scheduler/fs/IRQ/IPC/binder) โ no merge without measurement.
What the kernel is made of
Every subsystem has its own design page with mechanisms, data structures and measured numbers. Summary below.
๐งฎScheduler
A single global run queue (GRQ): aimed at desktop/mobile core counts within 8 vCPUs, it eliminates load balancing and task stealing by construction; the measured-wait wakeup gate ends the per-record preempt round trip.
๐ง Memory management
Buddy allocator + magazine small-object allocation, global page cache, per-task VMAs; the munmap churn-race family fully closed.
๐พFile systems
ext4 (rw) + async batched block reads + buffer-cache hit-rate protection; pbench filesystem medians all within the allowed band.
๐กIPC & binder
A complete OpenHarmony-compatible binder, unix sockets, pipes, SysV IPC; the cross-process deadlock family fixed and regressed.
๐Network stack
Hand-written TCP/IP stack: socket API semantics aligned; loopback and local paths continuously verified by LTP socket families and benchmarks.
๐Drivers
virtio-blk (PCI/MMIO, async completion rings), serial console, input; the display path carries GNOME and OH rendering.
๐Observability
A unified trace-event framework + tracefs (semantics aligned with Linux's, 69 events / 17 groups), the syscost census with the IF=0 probe, the pbench microbenchmarks, the compile-time kallsyms table, task dumps and the watchdog; the debugging section carries five deep-dive pages (tracepoints/perf/locks/memory forensics/panic).
๐งญArch port layer
Boot protocols (bzImage / image headers), trap entry, context switch, TLB management; ~90% of the kernel is arch-independent.
The numbers
Four standalone sections: Testing (LTP / stability / stress), Performance (gates + benchmark panel + optimization ledger), Security (taxonomy + formal verification + gap register) โ every number carries its test platform and date.
๐งชLTP compliance
The full 1,869-case scan grew from 35 early passes to 1,122 on the 2026-11-15 audited round, then to the official corrected 1,138 of the 2026-11-16 confirmation scan (scan3 โ all 17 expected gains materialized; the one real loss, tgkill03, root-caused and fixed); every round is archived and suspect rows are isolated-rerun twice before being called regressions; the TIMEOUT class is adjudicated row by row under the P0 rule. With the tgkill03 fix (procfs pid-dentry revalidation) merged to main, the current expected count is 1,139.
๐ก๏ธStability & stress
Kernel suite green on three architectures, 2,100 s desktop gates ร3, census/heal self-correction MISS=0; the 22.04 GNOME desktop stability-verified 5/5 boots on main 188+ commits past the previous campaign (shell up 5 s, desktop frame 9.1 s, zero panics/OOM/SIGSEGV); a standing 11-QEMU concurrent stress cluster (randomized/fuzz/memstorm); the riscv64 boot-parameter matrix smp{2,4,6,8} ร mem{1,2,4,8}G is clean in all sixteen cells (previously several panic/hang cells).
๐Performance
Three gate tiers + six guarded domains. Same-test platform vs Linux (2026-11-16 standing; the Linux column is a guest kernel in the same test platform): lmbench 14 of 21 paired cases ahead or at parity (pipe 4.6ร, context switch 4.0โ4.5ร, semaphore 2.9ร), 7 behind (the plain-syscall band 1.2โ2.5ร, open worst at 1.9โ2.5ร); Geekbench 5 SC 2465 / MC 7504 (vs the Linux 4-CPU anchor 113% / 114%); filesystem flush 128 MB (x86_64 KVM): fsync 11.55โ3.04 s, msync 13.95โ3.31 s, sync 11.30โ3.31 s.
๐Security
All 33 memory-corruption defects in history individually adjudicated (23 audited unsafe/asm + 10 safe ownership-class), zero pointer-expression defects in safe code; 164 Kani harnesses prove the core unsafe code for all inputs.
Three commands
A Linux host + QEMU is all you need. Full requirements, toolchains and troubleshooting in Getting started.
โ Clone
git clone https://github.com/topkernel/Rux
cd Rux
A pure Rust workspace โ no submodules, no vendored dependency images.
โกBuild
make build # riscv64 (default)
make build PLATFORM=x86_64 # x86_64
Kernel.toml is compiled into kernel/src/config.rs at build time.
โขRun
make run # musl minimal rootfs โ shell
make ubuntu-run # full Ubuntu 24.04 desktop (serial login: root / rux)
The serial port (ttyS0) is the primary log; GUI images boot with -snapshot so the shared image is never written.