opcode enc and dec