Search in sources :

Example 96 with RegisterSpecList

use of com.android.dx.rop.code.RegisterSpecList in project buck by facebook.

the class Form31i method compatibleRegs.

/** {@inheritDoc} */
@Override
public BitSet compatibleRegs(DalvInsn insn) {
    RegisterSpecList regs = insn.getRegisters();
    BitSet bits = new BitSet(1);
    bits.set(0, unsignedFitsInByte(regs.get(0).getReg()));
    return bits;
}
Also used : BitSet(java.util.BitSet) RegisterSpecList(com.android.dx.rop.code.RegisterSpecList)

Example 97 with RegisterSpecList

use of com.android.dx.rop.code.RegisterSpecList in project buck by facebook.

the class Form31t method compatibleRegs.

/** {@inheritDoc} */
@Override
public BitSet compatibleRegs(DalvInsn insn) {
    RegisterSpecList regs = insn.getRegisters();
    BitSet bits = new BitSet(1);
    bits.set(0, unsignedFitsInByte(regs.get(0).getReg()));
    return bits;
}
Also used : BitSet(java.util.BitSet) RegisterSpecList(com.android.dx.rop.code.RegisterSpecList)

Example 98 with RegisterSpecList

use of com.android.dx.rop.code.RegisterSpecList in project buck by facebook.

the class Form31t method writeTo.

/** {@inheritDoc} */
@Override
public void writeTo(AnnotatedOutput out, DalvInsn insn) {
    RegisterSpecList regs = insn.getRegisters();
    int offset = ((TargetInsn) insn).getTargetOffset();
    write(out, opcodeUnit(insn, regs.get(0).getReg()), offset);
}
Also used : TargetInsn(com.android.dx.dex.code.TargetInsn) RegisterSpecList(com.android.dx.rop.code.RegisterSpecList)

Aggregations

RegisterSpecList (com.android.dx.rop.code.RegisterSpecList)98 RegisterSpec (com.android.dx.rop.code.RegisterSpec)24 BitSet (java.util.BitSet)22 CstLiteralBits (com.android.dx.rop.cst.CstLiteralBits)21 CstInsn (com.android.dx.dex.code.CstInsn)17 Constant (com.android.dx.rop.cst.Constant)17 PlainInsn (com.android.dx.rop.code.PlainInsn)9 CstType (com.android.dx.rop.cst.CstType)6 TargetInsn (com.android.dx.dex.code.TargetInsn)5 Insn (com.android.dx.rop.code.Insn)5 TypedConstant (com.android.dx.rop.cst.TypedConstant)5 PlainCstInsn (com.android.dx.rop.code.PlainCstInsn)4 Rop (com.android.dx.rop.code.Rop)4 CstFieldRef (com.android.dx.rop.cst.CstFieldRef)4 TypeBearer (com.android.dx.rop.type.TypeBearer)4 ThrowingCstInsn (com.android.dx.rop.code.ThrowingCstInsn)3 ThrowingInsn (com.android.dx.rop.code.ThrowingInsn)3 CstInteger (com.android.dx.rop.cst.CstInteger)3 CstMethodRef (com.android.dx.rop.cst.CstMethodRef)3 FillArrayDataInsn (com.android.dx.rop.code.FillArrayDataInsn)2