Kern

Documentation

These pages are generated from the markdown files in the Kern repository. The language guide is the best place to start. The design records are working documents: where the code differs from a record, the code is the reference.

Guide

Language guide
Build, run, modules, generics, ownership, quality rules, targets.
Language spec
The compact language specification.
Standard library
The public API of every std module.
Structured concurrency
Tasks, channels and scopes: contract and state.
Embedded targets
The O1-O2 optimizer and the MCU phases M0-M7.
Reference service
An HTTP JSON and PostgreSQL service in pure Kern.
Compiler
Bootstrap and policy of the self-hosted compiler.

Design records

Plan
Goal, what is done, and the backend readiness steps.
Concurrency: next
select, fd readiness and multi-core designs.
Fixed arrays
Fixed arrays and static storage.
Test sharding
Test-runner sharding: measurement and design.
Optimizer audit
Self-hosted backend instruction costs.
M0 design
Target profiles and capabilities for MCUs.
M1 toolchain
External MCU toolchain spike.
M2 runtime
MCU runtime contract.
M3 MMIO
Volatile MMIO, arrays, interrupts.
M4 sizes
MCU size budgets.
M5 Thumb-2
Direct Thumb-2 encoder and ELF32 writer.
M6 tasks
Tasks on MCUs (design only).
MCU sizes
Measured MCU binary sizes.
M0-S0 results
Results of the M0 spike S0.
M0-S3 results
Results of the M0 spike S3.