Not an implemented or verified architecture. This earlier hardware sketch remains speculative. The revised stack starts on existing hardware and defines authority, replay, effects, and failure tests. Instruction encodings, capability compression, revocation, concurrency semantics, and performance need a formal specification and experiments before implementation.
0. design principles
six rules, in priority order. everything below follows from these.
1. regularity over cleverness. proposed instructions are 4 bytes; integer registers and addresses are 64 bits. capability registers need a separate representation.
2. capability over permission. no ambient authority. every pointer carries its own rights (read, write, execute, seal, derive). hardware enforces. no confused deputy.
3. content over location. persistent immutable artifacts may be identified by hash; RAM remains conventionally addressed. Hashing, deduplication, and retention have real costs.
4. explicit replay scope. reproducibility requires controlled or recorded nondeterminism, scheduling, numeric semantics, and initial state—not just identical external inputs.
5. observability over opacity. every instruction is traceable. every memory access is auditable. no black boxes. the machine explains itself.
6. composition over monolith. small, well-defined interfaces. components snap together. no god objects.
U-type conceptual fields: opcode(7) | rd(5) | imm(20) = 32 bits. These are not assigned opcodes or an assembler specification; two-register branches still require a defined operand layout.
4 types instead of 6 (RISC-V has 6). simpler decoder. no B-type or J-type (branches use I-type with PC-relative offset, jumps use U-type + I-type).
tag — 1 bit: 1 = valid capability, 0 = not a capability (prevents forging)
tag bit is the key: a capability is only valid if its tag bit is 1. any write to a capability register or memory location clears the tag. you cannot forge a capability by writing to memory — the tag bit is set only by the hardware on capability operations.
capability operations
CGETPERM cd, cs — read permissions from cs into cd (as integer)
CSETPERM cd, cs, rt — set permissions on cd from cs, masked by rt (can only reduce permissions)
CGETBASE cd, cs — read base address from cs
CSETBASE cd, cs, rt — set base address on cd (must be within bounds)
CGETLEN cd, cs — read length from cs
CSETLEN cd, cs, rt — set length on cd (can only shrink)
CSEAL cd, cs, ct — seal cd with type from ct (makes it opaque; cannot be used as pointer until unsealed)
CUNSEAL cd, cs, ct — unseal cd if type matches ct (restores pointer usability)
CCHKPERM cs, rt — trap if cs doesn't have permissions in rt
CCHKTYPE cs, rt — trap if cs type doesn't match rt
CLOAD cd, cs — load a capability from memory (cs points to capability in memory; tag must be valid)
CSTORE cs, ct — store a capability to memory (ct points to destination; tag preserved)
capability rules (hardware-enforced)
monotonicity: permissions can only be reduced, never increased (CSETPERM, CSETLEN)
bounds: check the entire access width, alignment, permissions, validity and sealing state using overflow-safe bounds arithmetic. Checking only the starting address is insufficient.
sealing: sealed capabilities cannot be dereferenced. only the sealer type can unseal.
no forging: tag bit is cleared on any non-capability write. only capability operations set it.
global: global capabilities (G permission) survive across compartment boundaries.
no ambient authority. a process can only access I/O devices through capabilities. no "open any file" or "connect to any host." every I/O channel is a capability granted by the parent.
structured I/O. data is not raw bytes — it's typed, schema-described messages. every read returns a typed value, not a byte stream. (like Cap'n Proto / FlatBuffers but at the kernel level.)
self-describing. every data structure carries its schema. no separate .proto file needed. (like BSON or CBOR with schema tags.)
versioned. every protocol message has a version number. old versions are supported forever (backward compatible). new versions add fields (forward compatible).
async-by-default. all I/O is asynchronous. no blocking calls. (like io_uring but for everything.)
I/O channels (capabilities)
console — text I/O (stdin/stdout/stderr). capability-gated.
filesystem — file read/write. capability grants access to a subtree (like a chroot capability).
network — socket creation. capability grants access to specific hosts/ports.
timer — time and timer. capability grants access to clock and timer creation.
random — randomness. capability grants access to CSPRNG.
process — process creation. capability grants right to fork/exec with specified capabilities.
memory — memory allocation. capability grants right to allocate memory of specified size/type.
instruction trace. optional privileged diagnostic tracing. Bandwidth, storage, execution overhead, and secret exposure must be measured; zero overhead is not claimed.
memory trace. every memory access is logged: address, value, read/write, cache hit/miss. (for debugging and verification.)
I/O trace. every I/O operation is logged: channel, operation, data, result. (for auditing and replay.)
capability trace. every capability operation is logged: creation, derivation, sealing, use. (for security auditing.)
deterministic replay
record. log all non-deterministic inputs (I/O results, timer values, randomness) during execution.
replay. supply recorded effect results without repeating live writes. Whole-machine replay additionally needs controlled or recorded scheduling, interrupts, relevant memory interleavings, atomic outcomes, and transaction aborts.
time travel. step backward in execution. inspect state at any point. (like rr but built into hardware.)
7. what we left out (and why)
every omission is a deliberate choice.
no segmentation. flat address space. (x86 segmentation was a mistake — complex, buggy, and unnecessary.)
no privilege rings. protection via capabilities, not privilege levels. (rings are coarse-grained and complex. capabilities are fine-grained and simple.)
no condition codes. comparisons set registers. (condition codes are hidden state that makes out-of-order execution harder.)
no delay slots. branches take effect immediately. (delay slots are a source of bugs and complicate compilers.)
no variable-length instructions. all instructions are 4 bytes. (variable-length makes decoding complex and prevents simple pipelining.)
no implicit memory. all memory access is explicit (load/store). (register-memory architectures (x86) make pipelining harder.)
no ambient authority. every resource access requires a capability. (prevents confused deputy, enables fine-grained sandboxing.)
no mutable shared state. data is immutable by default. (makes reasoning about concurrency trivial.)
8. comparison with existing architectures
what we took from each, and what we rejected.
RISC-V: took the clean ISA design, modular extensions, no condition codes, no delay slots. rejected: no capability support, no content-addressing.
CHERI: took the capability model (tagged pointers, monotonic permissions, sealing). rejected: complexity of retrofitting onto existing ISAs.
ARM: took the load-store architecture, unified register file, condition codes (rejected), NEON SIMD. rejected: complex instruction encoding, too many special cases.
x86-64: took the 64-bit address space, page-based virtual memory. rejected: segmentation, privilege rings, variable-length instructions, condition codes, CISC complexity.
MIPS: took the RISC simplicity. rejected: delay slots, branch prediction burden.
IPFS/content-addressing: took content-addressable storage, immutable data, deduplication. rejected: too slow for main memory (used for storage, not RAM).
Rust/ownership: took the idea of ownership and borrowing (capabilities are the hardware equivalent). rejected: (Rust is software; we want hardware enforcement.)
io_uring: took async-by-default I/O. rejected: (io_uring is a Linux API; we want it in the ISA.)
This sketch is a proposal, not a consequence proven by the corpus. See the revised stack for primary sources, explicit boundaries, and acceptance experiments.