Instruction Quick Reference

A compact summary of all 24 bytecode instructions. See the Instruction Set for full encoding details.

Cpu (0x00)

Stack manipulation, constants, and control flow (FLAIR-aligned).

InstructionOpcodeStack EffectDescription
const_int0x0200( -- int)Push 64-bit integer constant
const_float0x0300( -- float)Push 64-bit float constant
dup0x0400(a -- a a)Duplicate top of stack
pop0x0500(a -- )Discard top of stack
swap0x0600(a b -- b a)Swap top two elements
return0x6400( -- )Return from program
halt0xFF00( -- )Halt execution

LaneConstants (0x0F)

Address constant instructions.

InstructionOpcodeStack EffectDescription
const_loc0x000F( -- loc)Push location address
const_lane0x010F( -- lane)Push lane address
const_zone0x020F( -- zone)Push zone address

AtomArrangement (0x10)

Atom filling and transport.

InstructionOpcodeStack EffectDescription
initial_fill0x0010(loc₁..locₙ -- )Initial atom loading
fill0x0110(loc₁..locₙ -- )Atom refill
move0x0210(lane₁..laneₙ -- )Atom transport along lanes

QuantumGate (0x11)

Single- and multi-qubit gate operations.

InstructionOpcodeStack EffectDescription
local_r0x0011(loc₁..locₙ θ φ -- )Local R rotation
local_rz0x0111(loc₁..locₙ θ -- )Local Rz rotation
global_r0x0211(θ φ -- )Global R rotation
global_rz0x0311(θ -- )Global Rz rotation
cz0x0411(zone -- )Controlled-Z gate on zone

Measurement (0x12)

Qubit measurement.

InstructionOpcodeStack EffectDescription
measure0x0012(zone₁..zoneₙ -- future₁..futureₙ)Initiate measurement
await_measure0x0112(future -- array_ref)Wait for measurement result

Array (0x13)

Array construction and indexing.

InstructionOpcodeStack EffectDescription
new_array0x0013(elem₁..elemₙ -- array_ref)Construct array from stack
get_item0x0113(array_ref idx₁..idxₙ -- value)Index into array

DetectorObservable (0x14)

Detector and observable setup.

InstructionOpcodeStack EffectDescription
set_detector0x0014(array_ref -- detector_ref)Set detector
set_observable0x0114(array_ref -- observable_ref)Set observable