Index: runtime/vm/assembler_mips.h |
diff --git a/runtime/vm/assembler_mips.h b/runtime/vm/assembler_mips.h |
index 7073e3078830b282307b06d35b3b03f4fb5be6e4..2236b7fc3d8b6fe6766d4731c71a057ecbdede2f 100644 |
--- a/runtime/vm/assembler_mips.h |
+++ b/runtime/vm/assembler_mips.h |
@@ -162,20 +162,10 @@ class Condition : public ValueObject { |
: public BitField<uword, RelationOperator, kRelOpPos, kRelOpSize> {}; |
class ImmBits : public BitField<uword, uint16_t, kImmPos, kImmSize> {}; |
- Register left() const { |
- ASSERT(IsValid()); |
- return LeftBits::decode(bits_); |
- } |
- |
- Register right() const { |
- ASSERT(IsValid()); |
- return RightBits::decode(bits_); |
- } |
+ Register left() const { return LeftBits::decode(bits_); } |
+ Register right() const { return RightBits::decode(bits_); } |
RelationOperator rel_op() const { return RelOpBits::decode(bits_); } |
- int16_t imm() const { |
- ASSERT(IsValid()); |
- return static_cast<int16_t>(ImmBits::decode(bits_)); |
- } |
+ int16_t imm() const { return static_cast<int16_t>(ImmBits::decode(bits_)); } |
static bool IsValidImm(int32_t value) { |
// We want both value and value + 1 to fit in an int16_t. |
@@ -187,10 +177,8 @@ class Condition : public ValueObject { |
bits_ = RelOpBits::update(value, bits_); |
} |
- bool IsValid() const { return rel_op() != INVALID_RELATION; } |
- |
// Uninitialized condition. |
- Condition() : ValueObject(), bits_(RelOpBits::update(INVALID_RELATION, 0)) {} |
+ Condition() : ValueObject(), bits_(0) {} |
// Copy constructor. |
Condition(const Condition& other) : ValueObject(), bits_(other.bits_) {} |
@@ -212,19 +200,11 @@ class Condition : public ValueObject { |
ASSERT((imm != 0) == ((left == IMM) || (right == IMM))); |
set_left(left); |
set_right(right); |
- if (rel_op == INVALID_RELATION) { |
- SetToInvalidState(); |
- } else { |
- set_rel_op(rel_op); |
- } |
+ set_rel_op(rel_op); |
set_imm(imm); |
} |
private: |
- void SetToInvalidState() { |
- bits_ = RelOpBits::update(INVALID_RELATION, bits_); |
- } |
- |
static bool IsValidRelOp(RelationOperator value) { |
return (AL <= value) && (value <= ULE); |
} |