Assembler.TypesThis module contains OCaml types for PISA and PASM instructinos and programs. The Rocq types in the project's theories are mapped to these using an extraction script.
type 'l asm_inst = | Li of reg * intLoad immediate.
*)| Ld of reg * reg * intLoad.
*)| St of reg * reg * intStore.
*)| Add of reg * reg * regAdd two registers.
*)| Addi of reg * reg * intAdd register and immediate.
*)| Sub of reg * reg * regSubtract two registers.
*)| And of reg * reg * regBitwise and between two registers.
*)| Not of reg * regBitwise negation of a register.
*)| Sl of reg * reg * intLogical Shift Left.
*)| Sr of reg * reg * intLogical Shift Right.
*)| Beq of reg * reg * 'lBranch if equal-to.
*)| Blt of reg * reg * 'lBranch if less-than.
*)| Jalr of reg * reg * intJump and link register.
*)| Apc of reg * intAdd to PC and store in a register.
*)| J of 'l(Unconditional) jump.
*)| Label of 'lDefine a label.
*)| SpinSpin endlessly.
*)PASM instructions with labels of type 'l.
type 'l asm_prog = 'l asm_inst listPASM programs.
type isa_inst = | I_li of reg * int| I_ld of reg * reg * int| I_st of reg * reg * int| I_add of reg * reg * reg| I_addi of reg * reg * int| I_sub of reg * reg * reg| I_and of reg * reg * reg| I_not of reg * reg| I_sl of reg * reg * int| I_sr of reg * reg * int| I_beq of reg * reg * int| I_blt of reg * reg * int| I_jalr of reg * reg * int| I_apc of reg * int| I_j of intPISA instructions, without labels.
type isa_prog = isa_inst listPISA programs.
type machine_prog = machine_inst listMachine programs.
module Helper : sig ... endHelper functions to write AST programs.