@Override
    public void encode(DecodedInstruction insn, CodeOutput out) {
      long literal = insn.getLiteral();
      out.write(
          codeUnit(insn.getOpcode(), insn.getA()),
          unit0(literal),
          unit1(literal),
          unit2(literal),
          unit3(literal));
    }
Representation of an instruction format, which knows how to decode into and encode from instances
of {@link DecodedInstruction}.
android/android_framework/dex-maker/src/main/java/com/android/dx/io/instructions/InstructionCodec.java