Lines Matching refs:INSN_SIZE
27 pub const INSN_SIZE: usize = 8; constant
29 pub const PROG_MAX_SIZE: usize = PROG_MAX_INSNS * INSN_SIZE;
476 pub fn to_array(&self) -> [u8; INSN_SIZE] { in to_array() argument
558 if (idx + 1) * INSN_SIZE > prog.len() { in get_insn()
566 opc: prog[INSN_SIZE * idx], in get_insn()
567 dst: prog[INSN_SIZE * idx + 1] & 0x0f, in get_insn()
568 src: (prog[INSN_SIZE * idx + 1] & 0xf0) >> 4, in get_insn()
569 off: LittleEndian::read_i16(&prog[(INSN_SIZE * idx + 2)..]), in get_insn()
570 imm: LittleEndian::read_i32(&prog[(INSN_SIZE * idx + 4)..]), in get_insn()
619 if prog.len() % INSN_SIZE != 0 { in to_insn_vec()
622 INSN_SIZE in to_insn_vec()
629 while insn_ptr * INSN_SIZE < prog.len() { in to_insn_vec()