Built end-to-end by AI agents ยท humans review and merge

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.

Rust no_std POSIX compatible 349 syscalls x86_64 ยท riscv64 ยท aarch64 ext4 / binder / ELF
git clone https://github.com/topkernel/Rux.git
rux โ€” zsh
# โ‘  Unmodified Ubuntu 24.04 boots (x86_64 + KVM; make ubuntu-run default)
$ make ubuntu-run
[ rux ] smp: 4 vCPU online (q35)
[ rux ] virtio-blk: root mounted (ext4)
[ ubuntu ] systemd 255 โ€” multi-user + graphical targets
[ gdm ] started clean โ€” no 90 s timeout
[ ttyS0 ] serial login prompt โœ“ (root / rux)
# โ‘ก Unmodified OpenHarmony โ†’ all services
$ ./oh-boot.sh --accel kvm
[ rux ] binder: global context ready
[ oh ] servicemgr: 135+ services up
[ launcher ] home screen rendered โœ“
# โ‘ข In-kernel test suite
$ make test
1584 / 1584 passed โœ“ (riscv64)
โ–Œ ABI is the contract; internals are free.
409k+
lines of Rust
349
syscalls
4560+
test cases
3
architectures
1139/1869
LTP passing
29
design divergences (registered)
Boots ยท verified on real images

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.

Platforms ยท three architectures

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.

ArchitectureQEMU machineAccelUserspaceStatus
x86_64q35KVM (primary)Ubuntu 22.04 + 24.04 (glibc)22.04 GNOME desktop 5/5 ยท 24.04 graphical targets + serial login ยท main LTP/perf test platform
riscv64virtTCG (MTTCG)Ubuntu 22.04 / musl minimal rootfsDesktop + kernel suite 1584/1584
aarch64virt (gic-version=3)TCGInteractive shellshell / signals / kernel suite green
Design ยท tenets

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.

349 syscalls ยท LTP 1139/1869
Divergence register โ†’

๐Ÿ›ก๏ธ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.

unsafe lines 14.0% (dual series) ยท Kani 164 proofs
Security section โ†’

๐Ÿค–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.

worktrees 200+

โšก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.

GRQ critical section ~0.06โ€“0.08 ยตs (production ~60 ns; the old 0.24โ€“0.27 ยตs reading carried ~190 ns of probe self-cost)
Performance section โ†’
Modules ยท map

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.

critical section ~0.06โ€“0.08 ยตs ยท census 8/32 within the allowed band
Design โ†’

๐Ÿง Memory management

Buddy allocator + magazine small-object allocation, global page cache, per-task VMAs; the munmap churn-race family fully closed.

class-lock sections 19.7M/boot ยท gate โ‰ค25M
Design โ†’

๐Ÿ’พFile systems

ext4 (rw) + async batched block reads + buffer-cache hit-rate protection; pbench filesystem medians all within the allowed band.

buffer cache hit rate 99.1%
Design โ†’

๐Ÿ“กIPC & binder

A complete OpenHarmony-compatible binder, unix sockets, pipes, SysV IPC; the cross-process deadlock family fixed and regressed.

pipe round trip ยตs class ยท full OH service mesh
Design โ†’

๐ŸŒNetwork stack

Hand-written TCP/IP stack: socket API semantics aligned; loopback and local paths continuously verified by LTP socket families and benchmarks.

socket families growing in LTP
Design โ†’

๐Ÿ”ŒDrivers

virtio-blk (PCI/MMIO, async completion rings), serial console, input; the display path carries GNOME and OH rendering.

completion path rebuilt through several concurrency rounds
Design โ†’

๐Ÿ”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).

new observability is tracepoint-only
Design โ†’

๐ŸงญArch port layer

Boot protocols (bzImage / image headers), trap entry, context switch, TLB management; ~90% of the kernel is arch-independent.

x86_64 / riscv64 / aarch64
Design โ†’
Quality ยท sections

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.

current 1139 / 1869 (official scan3 1138 + the tgkill03 fix)
LTP scan โ†’

๐Ÿ›ก๏ธ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).

make test 1584/1584 ยท boot matrix 16/16 ยท GNOME 5/5
Stability โ†’

๐Ÿ“Š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.

14 of 21 paired cases ยท full ledger
Performance โ†’

๐Ÿ”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.

unsafe lines 14.0% (dual series) ยท gaps stated plainly
Security โ†’
Quickstart

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.