ternaria

Design decisions

Summaries only. Full reasoning, rejected options and later corrections are in the decision register.

Running

Emulator

A ternary machine in software, as QEMU is for binary machines.

PropertyValue
Word27 trits (≈42.8 bits), host i64
Double word54 trits, host i128
Addressable unit9 trits, a tryte
Instruction27 trits, fixed width
Immediate12 trits, ±265,720
Registers27, numbered r−13 to r13
Address spacesigned, ±3.81×1012 trytes
Unwritten memoryfaults; it is not zero
    addi r1, r0, 10
    addi r2, r0, 0
loop:
    addi r2, r2, 1
    addi r1, r1, -1
    br3  r1, loop
    halt

br3 branches three ways from one immediate, using the sign of the register to choose direction.

76tests
19,683tryte values checked exhaustively
21instructions
4crates, no dependencies

Contact