diff options
Diffstat (limited to 'deps/v8/src/lithium.h')
-rw-r--r-- | deps/v8/src/lithium.h | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/deps/v8/src/lithium.h b/deps/v8/src/lithium.h index 3253520090e..c0d7d076d9c 100644 --- a/deps/v8/src/lithium.h +++ b/deps/v8/src/lithium.h @@ -59,6 +59,7 @@ class LOperand: public ZoneObject { bool IsDoubleRegister() const { return kind() == DOUBLE_REGISTER; } bool IsArgument() const { return kind() == ARGUMENT; } bool IsUnallocated() const { return kind() == UNALLOCATED; } + bool IsIgnored() const { return kind() == INVALID; } bool Equals(LOperand* other) const { return value_ == other->value_; } int VirtualRegister(); @@ -89,8 +90,7 @@ class LUnallocated: public LOperand { FIXED_SLOT, MUST_HAVE_REGISTER, WRITABLE_REGISTER, - SAME_AS_FIRST_INPUT, - IGNORE + SAME_AS_FIRST_INPUT }; // Lifetime of operand inside the instruction. @@ -121,9 +121,9 @@ class LUnallocated: public LOperand { // The superclass has a KindField. Some policies have a signed fixed // index in the upper bits. - static const int kPolicyWidth = 4; + static const int kPolicyWidth = 3; static const int kLifetimeWidth = 1; - static const int kVirtualRegisterWidth = 17; + static const int kVirtualRegisterWidth = 18; static const int kPolicyShift = kKindFieldWidth; static const int kLifetimeShift = kPolicyShift + kPolicyWidth; @@ -143,12 +143,10 @@ class LUnallocated: public LOperand { kVirtualRegisterWidth> { }; - static const int kMaxVirtualRegisters = 1 << (kVirtualRegisterWidth + 1); + static const int kMaxVirtualRegisters = 1 << kVirtualRegisterWidth; static const int kMaxFixedIndex = 63; static const int kMinFixedIndex = -64; - bool HasIgnorePolicy() const { return policy() == IGNORE; } - bool HasNoPolicy() const { return policy() == NONE; } bool HasAnyPolicy() const { return policy() == ANY; } @@ -234,9 +232,7 @@ class LMoveOperands BASE_EMBEDDED { } bool IsIgnored() const { - return destination_ != NULL && - destination_->IsUnallocated() && - LUnallocated::cast(destination_)->HasIgnorePolicy(); + return destination_ != NULL && destination_->IsIgnored(); } // We clear both operands to indicate move that's been eliminated. @@ -443,12 +439,14 @@ class LPointerMap: public ZoneObject { class LEnvironment: public ZoneObject { public: LEnvironment(Handle<JSFunction> closure, + bool is_arguments_adaptor, int ast_id, int parameter_count, int argument_count, int value_count, LEnvironment* outer) : closure_(closure), + is_arguments_adaptor_(is_arguments_adaptor), arguments_stack_height_(argument_count), deoptimization_index_(Safepoint::kNoDeoptimizationIndex), translation_index_(-1), @@ -505,8 +503,11 @@ class LEnvironment: public ZoneObject { void PrintTo(StringStream* stream); + bool is_arguments_adaptor() const { return is_arguments_adaptor_; } + private: Handle<JSFunction> closure_; + bool is_arguments_adaptor_; int arguments_stack_height_; int deoptimization_index_; int translation_index_; |