diff options
Diffstat (limited to 'compiler/dex/mir_graph.h')
| -rw-r--r-- | compiler/dex/mir_graph.h | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/compiler/dex/mir_graph.h b/compiler/dex/mir_graph.h index 491d72e9e8..08b3ca4763 100644 --- a/compiler/dex/mir_graph.h +++ b/compiler/dex/mir_graph.h @@ -297,37 +297,37 @@ struct MIR { } bool IsInvoke() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kInvoke) == Instruction::kInvoke); + return ((FlagsOf() & Instruction::kInvoke) == Instruction::kInvoke); } bool IsStore() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kStore) == Instruction::kStore); + return ((FlagsOf() & Instruction::kStore) == Instruction::kStore); } bool IsLoad() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kLoad) == Instruction::kLoad); + return ((FlagsOf() & Instruction::kLoad) == Instruction::kLoad); } bool IsConditionalBranch() const { - return !IsPseudoMirOp(opcode) && (Instruction::FlagsOf(opcode) == (Instruction::kContinue | Instruction::kBranch)); + return (FlagsOf() == (Instruction::kContinue | Instruction::kBranch)); } /** * @brief Is the register C component of the decoded instruction a constant? */ bool IsCFieldOrConstant() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kRegCFieldOrConstant) == Instruction::kRegCFieldOrConstant); + return ((FlagsOf() & Instruction::kRegCFieldOrConstant) == Instruction::kRegCFieldOrConstant); } /** * @brief Is the register C component of the decoded instruction a constant? */ bool IsBFieldOrConstant() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kRegBFieldOrConstant) == Instruction::kRegBFieldOrConstant); + return ((FlagsOf() & Instruction::kRegBFieldOrConstant) == Instruction::kRegBFieldOrConstant); } bool IsCast() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kCast) == Instruction::kCast); + return ((FlagsOf() & Instruction::kCast) == Instruction::kCast); } /** @@ -337,12 +337,14 @@ struct MIR { * when crossing such an instruction. */ bool Clobbers() const { - return !IsPseudoMirOp(opcode) && ((Instruction::FlagsOf(opcode) & Instruction::kClobber) == Instruction::kClobber); + return ((FlagsOf() & Instruction::kClobber) == Instruction::kClobber); } bool IsLinear() const { - return !IsPseudoMirOp(opcode) && (Instruction::FlagsOf(opcode) & (Instruction::kAdd | Instruction::kSubtract)) != 0; + return (FlagsOf() & (Instruction::kAdd | Instruction::kSubtract)) != 0; } + + int FlagsOf() const; } dalvikInsn; NarrowDexOffset offset; // Offset of the instruction in code units. |