| Index: src/arm/lithium-codegen-arm.cc
|
| diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc
|
| index e07118317c464ba1041fc36814dfcfda6b56fb16..3c7abc38b56960f693265ee980fabed10f22626a 100644
|
| --- a/src/arm/lithium-codegen-arm.cc
|
| +++ b/src/arm/lithium-codegen-arm.cc
|
| @@ -951,7 +951,7 @@ void LCodeGen::DoUnknownOSRValue(LUnknownOSRValue* instr) {
|
|
|
| void LCodeGen::DoModI(LModI* instr) {
|
| if (instr->hydrogen()->HasPowerOf2Divisor()) {
|
| - Register dividend = ToRegister(instr->left());
|
| + Register dividend = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
|
|
| int32_t divisor =
|
| @@ -976,14 +976,14 @@ void LCodeGen::DoModI(LModI* instr) {
|
| }
|
|
|
| // These registers hold untagged 32 bit values.
|
| - Register left = ToRegister(instr->left());
|
| - Register right = ToRegister(instr->right());
|
| + Register left = ToRegister(instr->InputAt(0));
|
| + Register right = ToRegister(instr->InputAt(1));
|
| Register result = ToRegister(instr->result());
|
|
|
| Register scratch = scratch0();
|
| - Register scratch2 = ToRegister(instr->temp());
|
| - DwVfpRegister dividend = ToDoubleRegister(instr->temp2());
|
| - DwVfpRegister divisor = ToDoubleRegister(instr->temp3());
|
| + Register scratch2 = ToRegister(instr->TempAt(0));
|
| + DwVfpRegister dividend = ToDoubleRegister(instr->TempAt(1));
|
| + DwVfpRegister divisor = ToDoubleRegister(instr->TempAt(2));
|
| DwVfpRegister quotient = double_scratch0();
|
|
|
| ASSERT(!dividend.is(divisor));
|
| @@ -1186,18 +1186,15 @@ void LCodeGen::DoDivI(LDivI* instr) {
|
| DeferredDivI(LCodeGen* codegen, LDivI* instr)
|
| : LDeferredCode(codegen), instr_(instr) { }
|
| virtual void Generate() {
|
| - codegen()->DoDeferredBinaryOpStub(instr_->pointer_map(),
|
| - instr_->left(),
|
| - instr_->right(),
|
| - Token::DIV);
|
| + codegen()->DoDeferredBinaryOpStub(instr_, Token::DIV);
|
| }
|
| virtual LInstruction* instr() { return instr_; }
|
| private:
|
| LDivI* instr_;
|
| };
|
|
|
| - const Register left = ToRegister(instr->left());
|
| - const Register right = ToRegister(instr->right());
|
| + const Register left = ToRegister(instr->InputAt(0));
|
| + const Register right = ToRegister(instr->InputAt(1));
|
| const Register scratch = scratch0();
|
| const Register result = ToRegister(instr->result());
|
|
|
| @@ -1266,15 +1263,15 @@ void LCodeGen::DoDivI(LDivI* instr) {
|
|
|
| void LCodeGen::DoMathFloorOfDiv(LMathFloorOfDiv* instr) {
|
| const Register result = ToRegister(instr->result());
|
| - const Register left = ToRegister(instr->left());
|
| - const Register remainder = ToRegister(instr->temp());
|
| + const Register left = ToRegister(instr->InputAt(0));
|
| + const Register remainder = ToRegister(instr->TempAt(0));
|
| const Register scratch = scratch0();
|
|
|
| // We only optimize this for division by constants, because the standard
|
| // integer division routine is usually slower than transitionning to VFP.
|
| // This could be optimized on processors with SDIV available.
|
| - ASSERT(instr->right()->IsConstantOperand());
|
| - int32_t divisor = ToInteger32(LConstantOperand::cast(instr->right()));
|
| + ASSERT(instr->InputAt(1)->IsConstantOperand());
|
| + int32_t divisor = ToInteger32(LConstantOperand::cast(instr->InputAt(1)));
|
| if (divisor < 0) {
|
| __ cmp(left, Operand(0));
|
| DeoptimizeIf(eq, instr->environment());
|
| @@ -1292,12 +1289,11 @@ void LCodeGen::DoMathFloorOfDiv(LMathFloorOfDiv* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoDeferredBinaryOpStub(LPointerMap* pointer_map,
|
| - LOperand* left_argument,
|
| - LOperand* right_argument,
|
| +template<int T>
|
| +void LCodeGen::DoDeferredBinaryOpStub(LTemplateInstruction<1, 2, T>* instr,
|
| Token::Value op) {
|
| - Register left = ToRegister(left_argument);
|
| - Register right = ToRegister(right_argument);
|
| + Register left = ToRegister(instr->InputAt(0));
|
| + Register right = ToRegister(instr->InputAt(1));
|
|
|
| PushSafepointRegistersScope scope(this, Safepoint::kWithRegistersAndDoubles);
|
| // Move left to r1 and right to r0 for the stub call.
|
| @@ -1316,7 +1312,7 @@ void LCodeGen::DoDeferredBinaryOpStub(LPointerMap* pointer_map,
|
| }
|
| BinaryOpStub stub(op, OVERWRITE_LEFT);
|
| __ CallStub(&stub);
|
| - RecordSafepointWithRegistersAndDoubles(pointer_map,
|
| + RecordSafepointWithRegistersAndDoubles(instr->pointer_map(),
|
| 0,
|
| Safepoint::kNoLazyDeopt);
|
| // Overwrite the stored value of r0 with the result of the stub.
|
| @@ -1328,8 +1324,8 @@ void LCodeGen::DoMulI(LMulI* instr) {
|
| Register scratch = scratch0();
|
| Register result = ToRegister(instr->result());
|
| // Note that result may alias left.
|
| - Register left = ToRegister(instr->left());
|
| - LOperand* right_op = instr->right();
|
| + Register left = ToRegister(instr->InputAt(0));
|
| + LOperand* right_op = instr->InputAt(1);
|
|
|
| bool can_overflow = instr->hydrogen()->CheckFlag(HValue::kCanOverflow);
|
| bool bailout_on_minus_zero =
|
| @@ -1396,7 +1392,7 @@ void LCodeGen::DoMulI(LMulI* instr) {
|
| } else {
|
| Register right = EmitLoadRegister(right_op, scratch);
|
| if (bailout_on_minus_zero) {
|
| - __ orr(ToRegister(instr->temp()), left, right);
|
| + __ orr(ToRegister(instr->TempAt(0)), left, right);
|
| }
|
|
|
| if (can_overflow) {
|
| @@ -1413,7 +1409,7 @@ void LCodeGen::DoMulI(LMulI* instr) {
|
| Label done;
|
| __ cmp(result, Operand(0));
|
| __ b(ne, &done);
|
| - __ cmp(ToRegister(instr->temp()), Operand(0));
|
| + __ cmp(ToRegister(instr->TempAt(0)), Operand(0));
|
| DeoptimizeIf(mi, instr->environment());
|
| __ bind(&done);
|
| }
|
| @@ -1422,8 +1418,8 @@ void LCodeGen::DoMulI(LMulI* instr) {
|
|
|
|
|
| void LCodeGen::DoBitI(LBitI* instr) {
|
| - LOperand* left_op = instr->left();
|
| - LOperand* right_op = instr->right();
|
| + LOperand* left_op = instr->InputAt(0);
|
| + LOperand* right_op = instr->InputAt(1);
|
| ASSERT(left_op->IsRegister());
|
| Register left = ToRegister(left_op);
|
| Register result = ToRegister(instr->result());
|
| @@ -1456,8 +1452,8 @@ void LCodeGen::DoBitI(LBitI* instr) {
|
| void LCodeGen::DoShiftI(LShiftI* instr) {
|
| // Both 'left' and 'right' are "used at start" (see LCodeGen::DoShift), so
|
| // result may alias either of them.
|
| - LOperand* right_op = instr->right();
|
| - Register left = ToRegister(instr->left());
|
| + LOperand* right_op = instr->InputAt(1);
|
| + Register left = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| Register scratch = scratch0();
|
| if (right_op->IsRegister()) {
|
| @@ -1521,8 +1517,8 @@ void LCodeGen::DoShiftI(LShiftI* instr) {
|
|
|
|
|
| void LCodeGen::DoSubI(LSubI* instr) {
|
| - LOperand* left = instr->left();
|
| - LOperand* right = instr->right();
|
| + LOperand* left = instr->InputAt(0);
|
| + LOperand* right = instr->InputAt(1);
|
| LOperand* result = instr->result();
|
| bool can_overflow = instr->hydrogen()->CheckFlag(HValue::kCanOverflow);
|
| SBit set_cond = can_overflow ? SetCC : LeaveCC;
|
| @@ -1551,7 +1547,7 @@ void LCodeGen::DoConstantD(LConstantD* instr) {
|
| ASSERT(instr->result()->IsDoubleRegister());
|
| DwVfpRegister result = ToDoubleRegister(instr->result());
|
| double v = instr->value();
|
| - __ Vmov(result, v, scratch0());
|
| + __ Vmov(result, v);
|
| }
|
|
|
|
|
| @@ -1568,28 +1564,28 @@ void LCodeGen::DoConstantT(LConstantT* instr) {
|
|
|
| void LCodeGen::DoJSArrayLength(LJSArrayLength* instr) {
|
| Register result = ToRegister(instr->result());
|
| - Register array = ToRegister(instr->value());
|
| + Register array = ToRegister(instr->InputAt(0));
|
| __ ldr(result, FieldMemOperand(array, JSArray::kLengthOffset));
|
| }
|
|
|
|
|
| void LCodeGen::DoFixedArrayBaseLength(LFixedArrayBaseLength* instr) {
|
| Register result = ToRegister(instr->result());
|
| - Register array = ToRegister(instr->value());
|
| + Register array = ToRegister(instr->InputAt(0));
|
| __ ldr(result, FieldMemOperand(array, FixedArrayBase::kLengthOffset));
|
| }
|
|
|
|
|
| void LCodeGen::DoMapEnumLength(LMapEnumLength* instr) {
|
| Register result = ToRegister(instr->result());
|
| - Register map = ToRegister(instr->value());
|
| + Register map = ToRegister(instr->InputAt(0));
|
| __ EnumLength(result, map);
|
| }
|
|
|
|
|
| void LCodeGen::DoElementsKind(LElementsKind* instr) {
|
| Register result = ToRegister(instr->result());
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
|
|
| // Load map into |result|.
|
| __ ldr(result, FieldMemOperand(input, HeapObject::kMapOffset));
|
| @@ -1602,9 +1598,9 @@ void LCodeGen::DoElementsKind(LElementsKind* instr) {
|
|
|
|
|
| void LCodeGen::DoValueOf(LValueOf* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| - Register map = ToRegister(instr->temp());
|
| + Register map = ToRegister(instr->TempAt(0));
|
| Label done;
|
|
|
| // If the object is a smi return the object.
|
| @@ -1623,9 +1619,9 @@ void LCodeGen::DoValueOf(LValueOf* instr) {
|
|
|
|
|
| void LCodeGen::DoDateField(LDateField* instr) {
|
| - Register object = ToRegister(instr->date());
|
| + Register object = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| - Register scratch = ToRegister(instr->temp());
|
| + Register scratch = ToRegister(instr->TempAt(0));
|
| Smi* index = instr->index();
|
| Label runtime, done;
|
| ASSERT(object.is(result));
|
| @@ -1662,14 +1658,14 @@ void LCodeGen::DoDateField(LDateField* instr) {
|
|
|
|
|
| void LCodeGen::DoBitNotI(LBitNotI* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| __ mvn(result, Operand(input));
|
| }
|
|
|
|
|
| void LCodeGen::DoThrow(LThrow* instr) {
|
| - Register input_reg = EmitLoadRegister(instr->value(), ip);
|
| + Register input_reg = EmitLoadRegister(instr->InputAt(0), ip);
|
| __ push(input_reg);
|
| CallRuntime(Runtime::kThrow, 1, instr);
|
|
|
| @@ -1680,8 +1676,8 @@ void LCodeGen::DoThrow(LThrow* instr) {
|
|
|
|
|
| void LCodeGen::DoAddI(LAddI* instr) {
|
| - LOperand* left = instr->left();
|
| - LOperand* right = instr->right();
|
| + LOperand* left = instr->InputAt(0);
|
| + LOperand* right = instr->InputAt(1);
|
| LOperand* result = instr->result();
|
| bool can_overflow = instr->hydrogen()->CheckFlag(HValue::kCanOverflow);
|
| SBit set_cond = can_overflow ? SetCC : LeaveCC;
|
| @@ -1701,8 +1697,8 @@ void LCodeGen::DoAddI(LAddI* instr) {
|
|
|
|
|
| void LCodeGen::DoMathMinMax(LMathMinMax* instr) {
|
| - LOperand* left = instr->left();
|
| - LOperand* right = instr->right();
|
| + LOperand* left = instr->InputAt(0);
|
| + LOperand* right = instr->InputAt(1);
|
| HMathMinMax::Operation operation = instr->hydrogen()->operation();
|
| Condition condition = (operation == HMathMinMax::kMathMin) ? le : ge;
|
| if (instr->hydrogen()->representation().IsInteger32()) {
|
| @@ -1763,8 +1759,8 @@ void LCodeGen::DoMathMinMax(LMathMinMax* instr) {
|
|
|
|
|
| void LCodeGen::DoArithmeticD(LArithmeticD* instr) {
|
| - DoubleRegister left = ToDoubleRegister(instr->left());
|
| - DoubleRegister right = ToDoubleRegister(instr->right());
|
| + DoubleRegister left = ToDoubleRegister(instr->InputAt(0));
|
| + DoubleRegister right = ToDoubleRegister(instr->InputAt(1));
|
| DoubleRegister result = ToDoubleRegister(instr->result());
|
| switch (instr->op()) {
|
| case Token::ADD:
|
| @@ -1803,8 +1799,8 @@ void LCodeGen::DoArithmeticD(LArithmeticD* instr) {
|
|
|
|
|
| void LCodeGen::DoArithmeticT(LArithmeticT* instr) {
|
| - ASSERT(ToRegister(instr->left()).is(r1));
|
| - ASSERT(ToRegister(instr->right()).is(r0));
|
| + ASSERT(ToRegister(instr->InputAt(0)).is(r1));
|
| + ASSERT(ToRegister(instr->InputAt(1)).is(r0));
|
| ASSERT(ToRegister(instr->result()).is(r0));
|
|
|
| BinaryOpStub stub(instr->op(), NO_OVERWRITE);
|
| @@ -1849,11 +1845,11 @@ void LCodeGen::DoBranch(LBranch* instr) {
|
|
|
| Representation r = instr->hydrogen()->value()->representation();
|
| if (r.IsInteger32()) {
|
| - Register reg = ToRegister(instr->value());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| __ cmp(reg, Operand(0));
|
| EmitBranch(true_block, false_block, ne);
|
| } else if (r.IsDouble()) {
|
| - DoubleRegister reg = ToDoubleRegister(instr->value());
|
| + DoubleRegister reg = ToDoubleRegister(instr->InputAt(0));
|
| Register scratch = scratch0();
|
|
|
| // Test the double value. Zero and NaN are false.
|
| @@ -1862,7 +1858,7 @@ void LCodeGen::DoBranch(LBranch* instr) {
|
| EmitBranch(true_block, false_block, eq);
|
| } else {
|
| ASSERT(r.IsTagged());
|
| - Register reg = ToRegister(instr->value());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| HType type = instr->hydrogen()->value()->type();
|
| if (type.IsBoolean()) {
|
| __ CompareRoot(reg, Heap::kTrueValueRootIndex);
|
| @@ -2001,8 +1997,8 @@ Condition LCodeGen::TokenToCondition(Token::Value op, bool is_unsigned) {
|
|
|
|
|
| void LCodeGen::DoCmpIDAndBranch(LCmpIDAndBranch* instr) {
|
| - LOperand* left = instr->left();
|
| - LOperand* right = instr->right();
|
| + LOperand* left = instr->InputAt(0);
|
| + LOperand* right = instr->InputAt(1);
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| Condition cond = TokenToCondition(instr->op(), false);
|
| @@ -2042,8 +2038,8 @@ void LCodeGen::DoCmpIDAndBranch(LCmpIDAndBranch* instr) {
|
|
|
|
|
| void LCodeGen::DoCmpObjectEqAndBranch(LCmpObjectEqAndBranch* instr) {
|
| - Register left = ToRegister(instr->left());
|
| - Register right = ToRegister(instr->right());
|
| + Register left = ToRegister(instr->InputAt(0));
|
| + Register right = ToRegister(instr->InputAt(1));
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
|
|
| @@ -2053,7 +2049,7 @@ void LCodeGen::DoCmpObjectEqAndBranch(LCmpObjectEqAndBranch* instr) {
|
|
|
|
|
| void LCodeGen::DoCmpConstantEqAndBranch(LCmpConstantEqAndBranch* instr) {
|
| - Register left = ToRegister(instr->left());
|
| + Register left = ToRegister(instr->InputAt(0));
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
|
|
| @@ -2064,7 +2060,7 @@ void LCodeGen::DoCmpConstantEqAndBranch(LCmpConstantEqAndBranch* instr) {
|
|
|
| void LCodeGen::DoIsNilAndBranch(LIsNilAndBranch* instr) {
|
| Register scratch = scratch0();
|
| - Register reg = ToRegister(instr->value());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
|
|
| // If the expression is known to be untagged or a smi, then it's definitely
|
| @@ -2132,8 +2128,8 @@ Condition LCodeGen::EmitIsObject(Register input,
|
|
|
|
|
| void LCodeGen::DoIsObjectAndBranch(LIsObjectAndBranch* instr) {
|
| - Register reg = ToRegister(instr->value());
|
| - Register temp1 = ToRegister(instr->temp());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| + Register temp1 = ToRegister(instr->TempAt(0));
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| @@ -2158,8 +2154,8 @@ Condition LCodeGen::EmitIsString(Register input,
|
|
|
|
|
| void LCodeGen::DoIsStringAndBranch(LIsStringAndBranch* instr) {
|
| - Register reg = ToRegister(instr->value());
|
| - Register temp1 = ToRegister(instr->temp());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| + Register temp1 = ToRegister(instr->TempAt(0));
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| @@ -2176,15 +2172,15 @@ void LCodeGen::DoIsSmiAndBranch(LIsSmiAndBranch* instr) {
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
|
|
| - Register input_reg = EmitLoadRegister(instr->value(), ip);
|
| + Register input_reg = EmitLoadRegister(instr->InputAt(0), ip);
|
| __ tst(input_reg, Operand(kSmiTagMask));
|
| EmitBranch(true_block, false_block, eq);
|
| }
|
|
|
|
|
| void LCodeGen::DoIsUndetectableAndBranch(LIsUndetectableAndBranch* instr) {
|
| - Register input = ToRegister(instr->value());
|
| - Register temp = ToRegister(instr->temp());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| + Register temp = ToRegister(instr->TempAt(0));
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| @@ -2254,7 +2250,7 @@ static Condition BranchCondition(HHasInstanceTypeAndBranch* instr) {
|
|
|
| void LCodeGen::DoHasInstanceTypeAndBranch(LHasInstanceTypeAndBranch* instr) {
|
| Register scratch = scratch0();
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| @@ -2269,7 +2265,7 @@ void LCodeGen::DoHasInstanceTypeAndBranch(LHasInstanceTypeAndBranch* instr) {
|
|
|
|
|
| void LCodeGen::DoGetCachedArrayIndex(LGetCachedArrayIndex* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
|
|
| __ AbortIfNotString(input);
|
| @@ -2281,7 +2277,7 @@ void LCodeGen::DoGetCachedArrayIndex(LGetCachedArrayIndex* instr) {
|
|
|
| void LCodeGen::DoHasCachedArrayIndexAndBranch(
|
| LHasCachedArrayIndexAndBranch* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register scratch = scratch0();
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| @@ -2362,9 +2358,9 @@ void LCodeGen::EmitClassOfTest(Label* is_true,
|
|
|
|
|
| void LCodeGen::DoClassOfTestAndBranch(LClassOfTestAndBranch* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register temp = scratch0();
|
| - Register temp2 = ToRegister(instr->temp());
|
| + Register temp2 = ToRegister(instr->TempAt(0));
|
| Handle<String> class_name = instr->hydrogen()->class_name();
|
|
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| @@ -2380,8 +2376,8 @@ void LCodeGen::DoClassOfTestAndBranch(LClassOfTestAndBranch* instr) {
|
|
|
|
|
| void LCodeGen::DoCmpMapAndBranch(LCmpMapAndBranch* instr) {
|
| - Register reg = ToRegister(instr->value());
|
| - Register temp = ToRegister(instr->temp());
|
| + Register reg = ToRegister(instr->InputAt(0));
|
| + Register temp = ToRegister(instr->TempAt(0));
|
| int true_block = instr->true_block_id();
|
| int false_block = instr->false_block_id();
|
|
|
| @@ -2392,8 +2388,8 @@ void LCodeGen::DoCmpMapAndBranch(LCmpMapAndBranch* instr) {
|
|
|
|
|
| void LCodeGen::DoInstanceOf(LInstanceOf* instr) {
|
| - ASSERT(ToRegister(instr->left()).is(r0)); // Object is in r0.
|
| - ASSERT(ToRegister(instr->right()).is(r1)); // Function is in r1.
|
| + ASSERT(ToRegister(instr->InputAt(0)).is(r0)); // Object is in r0.
|
| + ASSERT(ToRegister(instr->InputAt(1)).is(r1)); // Function is in r1.
|
|
|
| InstanceofStub stub(InstanceofStub::kArgsInRegisters);
|
| CallCode(stub.GetCode(), RelocInfo::CODE_TARGET, instr);
|
| @@ -2424,8 +2420,8 @@ void LCodeGen::DoInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr) {
|
| deferred = new(zone()) DeferredInstanceOfKnownGlobal(this, instr);
|
|
|
| Label done, false_result;
|
| - Register object = ToRegister(instr->value());
|
| - Register temp = ToRegister(instr->temp());
|
| + Register object = ToRegister(instr->InputAt(0));
|
| + Register temp = ToRegister(instr->TempAt(0));
|
| Register result = ToRegister(instr->result());
|
|
|
| ASSERT(object.is(r0));
|
| @@ -2505,7 +2501,7 @@ void LCodeGen::DoDeferredInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr,
|
| // Get the temp register reserved by the instruction. This needs to be r4 as
|
| // its slot of the pushing of safepoint registers is used to communicate the
|
| // offset to the location of the map check.
|
| - Register temp = ToRegister(instr->temp());
|
| + Register temp = ToRegister(instr->TempAt(0));
|
| ASSERT(temp.is(r4));
|
| __ LoadHeapObject(InstanceofStub::right(), instr->function());
|
| static const int kAdditionalDelta = 5;
|
| @@ -2602,7 +2598,7 @@ void LCodeGen::DoStoreGlobalCell(LStoreGlobalCell* instr) {
|
| // it as no longer deleted.
|
| if (instr->hydrogen()->RequiresHoleCheck()) {
|
| // We use a temp to check the payload (CompareRoot might clobber ip).
|
| - Register payload = ToRegister(instr->temp());
|
| + Register payload = ToRegister(instr->TempAt(0));
|
| __ ldr(payload, FieldMemOperand(cell, JSGlobalPropertyCell::kValueOffset));
|
| __ CompareRoot(payload, Heap::kTheHoleValueRootIndex);
|
| DeoptimizeIf(eq, instr->environment());
|
| @@ -2681,7 +2677,7 @@ void LCodeGen::DoStoreContextSlot(LStoreContextSlot* instr) {
|
|
|
|
|
| void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) {
|
| - Register object = ToRegister(instr->object());
|
| + Register object = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| if (instr->hydrogen()->is_in_object()) {
|
| __ ldr(result, FieldMemOperand(object, instr->hydrogen()->offset()));
|
| @@ -2835,7 +2831,7 @@ void LCodeGen::DoLoadFunctionPrototype(LLoadFunctionPrototype* instr) {
|
|
|
| void LCodeGen::DoLoadElements(LLoadElements* instr) {
|
| Register result = ToRegister(instr->result());
|
| - Register input = ToRegister(instr->object());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register scratch = scratch0();
|
|
|
| __ ldr(result, FieldMemOperand(input, JSObject::kElementsOffset));
|
| @@ -2870,7 +2866,7 @@ void LCodeGen::DoLoadElements(LLoadElements* instr) {
|
| void LCodeGen::DoLoadExternalArrayPointer(
|
| LLoadExternalArrayPointer* instr) {
|
| Register to_reg = ToRegister(instr->result());
|
| - Register from_reg = ToRegister(instr->object());
|
| + Register from_reg = ToRegister(instr->InputAt(0));
|
| __ ldr(to_reg, FieldMemOperand(from_reg,
|
| ExternalArray::kExternalPointerOffset));
|
| }
|
| @@ -3127,7 +3123,7 @@ void LCodeGen::DoArgumentsElements(LArgumentsElements* instr) {
|
|
|
|
|
| void LCodeGen::DoArgumentsLength(LArgumentsLength* instr) {
|
| - Register elem = ToRegister(instr->elements());
|
| + Register elem = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
|
|
| Label done;
|
| @@ -3246,7 +3242,7 @@ void LCodeGen::DoApplyArguments(LApplyArguments* instr) {
|
|
|
|
|
| void LCodeGen::DoPushArgument(LPushArgument* instr) {
|
| - LOperand* argument = instr->value();
|
| + LOperand* argument = instr->InputAt(0);
|
| if (argument->IsDoubleRegister() || argument->IsDoubleStackSlot()) {
|
| Abort("DoPushArgument not implemented for double type.");
|
| } else {
|
| @@ -3298,7 +3294,7 @@ void LCodeGen::DoGlobalObject(LGlobalObject* instr) {
|
|
|
|
|
| void LCodeGen::DoGlobalReceiver(LGlobalReceiver* instr) {
|
| - Register global = ToRegister(instr->global_object());
|
| + Register global = ToRegister(instr->global());
|
| Register result = ToRegister(instr->result());
|
| __ ldr(result, FieldMemOperand(global, GlobalObject::kGlobalReceiverOffset));
|
| }
|
| @@ -3358,7 +3354,7 @@ void LCodeGen::DoCallConstantFunction(LCallConstantFunction* instr) {
|
|
|
|
|
| void LCodeGen::DoDeferredMathAbsTaggedHeapNumber(LUnaryMathOperation* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| Register scratch = scratch0();
|
|
|
| @@ -3424,7 +3420,7 @@ void LCodeGen::DoDeferredMathAbsTaggedHeapNumber(LUnaryMathOperation* instr) {
|
|
|
|
|
| void LCodeGen::EmitIntegerMathAbs(LUnaryMathOperation* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| __ cmp(input, Operand(0));
|
| __ Move(result, input, pl);
|
| @@ -3454,7 +3450,7 @@ void LCodeGen::DoMathAbs(LUnaryMathOperation* instr) {
|
|
|
| Representation r = instr->hydrogen()->value()->representation();
|
| if (r.IsDouble()) {
|
| - DwVfpRegister input = ToDoubleRegister(instr->value());
|
| + DwVfpRegister input = ToDoubleRegister(instr->InputAt(0));
|
| DwVfpRegister result = ToDoubleRegister(instr->result());
|
| __ vabs(result, input);
|
| } else if (r.IsInteger32()) {
|
| @@ -3463,7 +3459,7 @@ void LCodeGen::DoMathAbs(LUnaryMathOperation* instr) {
|
| // Representation is tagged.
|
| DeferredMathAbsTaggedHeapNumber* deferred =
|
| new(zone()) DeferredMathAbsTaggedHeapNumber(this, instr);
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| // Smi check.
|
| __ JumpIfNotSmi(input, deferred->entry());
|
| // If smi, handle it directly.
|
| @@ -3474,11 +3470,11 @@ void LCodeGen::DoMathAbs(LUnaryMathOperation* instr) {
|
|
|
|
|
| void LCodeGen::DoMathFloor(LUnaryMathOperation* instr) {
|
| - DoubleRegister input = ToDoubleRegister(instr->value());
|
| + DoubleRegister input = ToDoubleRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| SwVfpRegister single_scratch = double_scratch0().low();
|
| Register scratch1 = scratch0();
|
| - Register scratch2 = ToRegister(instr->temp());
|
| + Register scratch2 = ToRegister(instr->TempAt(0));
|
|
|
| __ EmitVFPTruncate(kRoundToMinusInf,
|
| single_scratch,
|
| @@ -3504,7 +3500,7 @@ void LCodeGen::DoMathFloor(LUnaryMathOperation* instr) {
|
|
|
|
|
| void LCodeGen::DoMathRound(LUnaryMathOperation* instr) {
|
| - DoubleRegister input = ToDoubleRegister(instr->value());
|
| + DoubleRegister input = ToDoubleRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| Register scratch = scratch0();
|
| Label done, check_sign_on_zero;
|
| @@ -3530,12 +3526,12 @@ void LCodeGen::DoMathRound(LUnaryMathOperation* instr) {
|
| __ cmp(scratch, Operand(HeapNumber::kExponentBias + 32));
|
| DeoptimizeIf(ge, instr->environment());
|
|
|
| - __ Vmov(double_scratch0(), 0.5, scratch);
|
| - __ vadd(double_scratch0(), input, double_scratch0());
|
| -
|
| // Save the original sign for later comparison.
|
| __ and_(scratch, result, Operand(HeapNumber::kSignMask));
|
|
|
| + __ Vmov(double_scratch0(), 0.5);
|
| + __ vadd(double_scratch0(), input, double_scratch0());
|
| +
|
| // Check sign of the result: if the sign changed, the input
|
| // value was in ]0.5, 0[ and the result should be -0.
|
| __ vmov(result, double_scratch0().high());
|
| @@ -3569,22 +3565,22 @@ void LCodeGen::DoMathRound(LUnaryMathOperation* instr) {
|
|
|
|
|
| void LCodeGen::DoMathSqrt(LUnaryMathOperation* instr) {
|
| - DoubleRegister input = ToDoubleRegister(instr->value());
|
| + DoubleRegister input = ToDoubleRegister(instr->InputAt(0));
|
| DoubleRegister result = ToDoubleRegister(instr->result());
|
| __ vsqrt(result, input);
|
| }
|
|
|
|
|
| void LCodeGen::DoMathPowHalf(LUnaryMathOperation* instr) {
|
| - DoubleRegister input = ToDoubleRegister(instr->value());
|
| + DoubleRegister input = ToDoubleRegister(instr->InputAt(0));
|
| DoubleRegister result = ToDoubleRegister(instr->result());
|
| - DoubleRegister temp = ToDoubleRegister(instr->temp());
|
| + DoubleRegister temp = ToDoubleRegister(instr->TempAt(0));
|
|
|
| // Note that according to ECMA-262 15.8.2.13:
|
| // Math.pow(-Infinity, 0.5) == Infinity
|
| // Math.sqrt(-Infinity) == NaN
|
| Label done;
|
| - __ vmov(temp, -V8_INFINITY, scratch0());
|
| + __ vmov(temp, -V8_INFINITY);
|
| __ VFPCompareAndSetFlags(input, temp);
|
| __ vneg(result, temp, eq);
|
| __ b(&done, eq);
|
| @@ -3600,11 +3596,11 @@ void LCodeGen::DoPower(LPower* instr) {
|
| Representation exponent_type = instr->hydrogen()->right()->representation();
|
| // Having marked this as a call, we can use any registers.
|
| // Just make sure that the input/output registers are the expected ones.
|
| - ASSERT(!instr->right()->IsDoubleRegister() ||
|
| - ToDoubleRegister(instr->right()).is(d2));
|
| - ASSERT(!instr->right()->IsRegister() ||
|
| - ToRegister(instr->right()).is(r2));
|
| - ASSERT(ToDoubleRegister(instr->left()).is(d1));
|
| + ASSERT(!instr->InputAt(1)->IsDoubleRegister() ||
|
| + ToDoubleRegister(instr->InputAt(1)).is(d2));
|
| + ASSERT(!instr->InputAt(1)->IsRegister() ||
|
| + ToRegister(instr->InputAt(1)).is(r2));
|
| + ASSERT(ToDoubleRegister(instr->InputAt(0)).is(d1));
|
| ASSERT(ToDoubleRegister(instr->result()).is(d3));
|
|
|
| if (exponent_type.IsTagged()) {
|
| @@ -3644,7 +3640,7 @@ void LCodeGen::DoRandom(LRandom* instr) {
|
| // Having marked this instruction as a call we can use any
|
| // registers.
|
| ASSERT(ToDoubleRegister(instr->result()).is(d7));
|
| - ASSERT(ToRegister(instr->global_object()).is(r0));
|
| + ASSERT(ToRegister(instr->InputAt(0)).is(r0));
|
|
|
| static const int kSeedSize = sizeof(uint32_t);
|
| STATIC_ASSERT(kPointerSize == kSeedSize);
|
| @@ -3855,7 +3851,7 @@ void LCodeGen::DoCallKnownGlobal(LCallKnownGlobal* instr) {
|
|
|
|
|
| void LCodeGen::DoCallNew(LCallNew* instr) {
|
| - ASSERT(ToRegister(instr->constructor()).is(r1));
|
| + ASSERT(ToRegister(instr->InputAt(0)).is(r1));
|
| ASSERT(ToRegister(instr->result()).is(r0));
|
|
|
| CallConstructStub stub(NO_CALL_FUNCTION_FLAGS);
|
| @@ -3881,7 +3877,7 @@ void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
|
| __ mov(scratch, Operand(instr->transition()));
|
| __ str(scratch, FieldMemOperand(object, HeapObject::kMapOffset));
|
| if (instr->hydrogen()->NeedsWriteBarrierForMap()) {
|
| - Register temp = ToRegister(instr->temp());
|
| + Register temp = ToRegister(instr->TempAt(0));
|
| // Update the write barrier for the map field.
|
| __ RecordWriteField(object,
|
| HeapObject::kMapOffset,
|
| @@ -4066,7 +4062,7 @@ void LCodeGen::DoStoreKeyedFastDoubleElement(
|
| // Only load canonical NaN if the comparison above set the overflow.
|
| __ Vmov(value,
|
| FixedDoubleArray::canonical_not_the_hole_nan_as_double(),
|
| - no_reg, vs);
|
| + vs);
|
| }
|
|
|
| __ vstr(value, scratch, instr->additional_index() << element_size_shift);
|
| @@ -4159,7 +4155,7 @@ void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) {
|
|
|
| void LCodeGen::DoTransitionElementsKind(LTransitionElementsKind* instr) {
|
| Register object_reg = ToRegister(instr->object());
|
| - Register new_map_reg = ToRegister(instr->new_map_temp());
|
| + Register new_map_reg = ToRegister(instr->new_map_reg());
|
| Register scratch = scratch0();
|
|
|
| Handle<Map> from_map = instr->original_map();
|
| @@ -4180,7 +4176,7 @@ void LCodeGen::DoTransitionElementsKind(LTransitionElementsKind* instr) {
|
| scratch, kLRHasBeenSaved, kDontSaveFPRegs);
|
| } else if (IsFastSmiElementsKind(from_kind) &&
|
| IsFastDoubleElementsKind(to_kind)) {
|
| - Register fixed_object_reg = ToRegister(instr->temp());
|
| + Register fixed_object_reg = ToRegister(instr->temp_reg());
|
| ASSERT(fixed_object_reg.is(r2));
|
| ASSERT(new_map_reg.is(r3));
|
| __ mov(fixed_object_reg, object_reg);
|
| @@ -4188,7 +4184,7 @@ void LCodeGen::DoTransitionElementsKind(LTransitionElementsKind* instr) {
|
| RelocInfo::CODE_TARGET, instr);
|
| } else if (IsFastDoubleElementsKind(from_kind) &&
|
| IsFastObjectElementsKind(to_kind)) {
|
| - Register fixed_object_reg = ToRegister(instr->temp());
|
| + Register fixed_object_reg = ToRegister(instr->temp_reg());
|
| ASSERT(fixed_object_reg.is(r2));
|
| ASSERT(new_map_reg.is(r3));
|
| __ mov(fixed_object_reg, object_reg);
|
| @@ -4313,14 +4309,14 @@ void LCodeGen::DoDeferredStringCharFromCode(LStringCharFromCode* instr) {
|
|
|
|
|
| void LCodeGen::DoStringLength(LStringLength* instr) {
|
| - Register string = ToRegister(instr->string());
|
| + Register string = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| __ ldr(result, FieldMemOperand(string, String::kLengthOffset));
|
| }
|
|
|
|
|
| void LCodeGen::DoInteger32ToDouble(LInteger32ToDouble* instr) {
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| ASSERT(input->IsRegister() || input->IsStackSlot());
|
| LOperand* output = instr->result();
|
| ASSERT(output->IsDoubleRegister());
|
| @@ -4337,7 +4333,7 @@ void LCodeGen::DoInteger32ToDouble(LInteger32ToDouble* instr) {
|
|
|
|
|
| void LCodeGen::DoUint32ToDouble(LUint32ToDouble* instr) {
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| LOperand* output = instr->result();
|
|
|
| SwVfpRegister flt_scratch = double_scratch0().low();
|
| @@ -4353,7 +4349,7 @@ void LCodeGen::DoNumberTagI(LNumberTagI* instr) {
|
| : LDeferredCode(codegen), instr_(instr) { }
|
| virtual void Generate() {
|
| codegen()->DoDeferredNumberTagI(instr_,
|
| - instr_->value(),
|
| + instr_->InputAt(0),
|
| SIGNED_INT32);
|
| }
|
| virtual LInstruction* instr() { return instr_; }
|
| @@ -4361,7 +4357,7 @@ void LCodeGen::DoNumberTagI(LNumberTagI* instr) {
|
| LNumberTagI* instr_;
|
| };
|
|
|
| - Register src = ToRegister(instr->value());
|
| + Register src = ToRegister(instr->InputAt(0));
|
| Register dst = ToRegister(instr->result());
|
|
|
| DeferredNumberTagI* deferred = new(zone()) DeferredNumberTagI(this, instr);
|
| @@ -4378,7 +4374,7 @@ void LCodeGen::DoNumberTagU(LNumberTagU* instr) {
|
| : LDeferredCode(codegen), instr_(instr) { }
|
| virtual void Generate() {
|
| codegen()->DoDeferredNumberTagI(instr_,
|
| - instr_->value(),
|
| + instr_->InputAt(0),
|
| UNSIGNED_INT32);
|
| }
|
| virtual LInstruction* instr() { return instr_; }
|
| @@ -4386,7 +4382,7 @@ void LCodeGen::DoNumberTagU(LNumberTagU* instr) {
|
| LNumberTagU* instr_;
|
| };
|
|
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| ASSERT(input->IsRegister() && input->Equals(instr->result()));
|
| Register reg = ToRegister(input);
|
|
|
| @@ -4464,11 +4460,11 @@ void LCodeGen::DoNumberTagD(LNumberTagD* instr) {
|
| LNumberTagD* instr_;
|
| };
|
|
|
| - DoubleRegister input_reg = ToDoubleRegister(instr->value());
|
| + DoubleRegister input_reg = ToDoubleRegister(instr->InputAt(0));
|
| Register scratch = scratch0();
|
| Register reg = ToRegister(instr->result());
|
| - Register temp1 = ToRegister(instr->temp());
|
| - Register temp2 = ToRegister(instr->temp2());
|
| + Register temp1 = ToRegister(instr->TempAt(0));
|
| + Register temp2 = ToRegister(instr->TempAt(1));
|
|
|
| DeferredNumberTagD* deferred = new(zone()) DeferredNumberTagD(this, instr);
|
| if (FLAG_inline_new) {
|
| @@ -4498,12 +4494,12 @@ void LCodeGen::DoDeferredNumberTagD(LNumberTagD* instr) {
|
|
|
| void LCodeGen::DoSmiTag(LSmiTag* instr) {
|
| ASSERT(!instr->hydrogen_value()->CheckFlag(HValue::kCanOverflow));
|
| - __ SmiTag(ToRegister(instr->result()), ToRegister(instr->value()));
|
| + __ SmiTag(ToRegister(instr->result()), ToRegister(instr->InputAt(0)));
|
| }
|
|
|
|
|
| void LCodeGen::DoSmiUntag(LSmiUntag* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register result = ToRegister(instr->result());
|
| if (instr->needs_check()) {
|
| STATIC_ASSERT(kHeapObjectTag == 1);
|
| @@ -4575,9 +4571,9 @@ void LCodeGen::EmitNumberUntagD(Register input_reg,
|
|
|
|
|
| void LCodeGen::DoDeferredTaggedToI(LTaggedToI* instr) {
|
| - Register input_reg = ToRegister(instr->value());
|
| + Register input_reg = ToRegister(instr->InputAt(0));
|
| Register scratch1 = scratch0();
|
| - Register scratch2 = ToRegister(instr->temp());
|
| + Register scratch2 = ToRegister(instr->TempAt(0));
|
| DwVfpRegister double_scratch = double_scratch0();
|
| SwVfpRegister single_scratch = double_scratch.low();
|
|
|
| @@ -4598,8 +4594,8 @@ void LCodeGen::DoDeferredTaggedToI(LTaggedToI* instr) {
|
| __ cmp(scratch1, Operand(ip));
|
|
|
| if (instr->truncating()) {
|
| - Register scratch3 = ToRegister(instr->temp2());
|
| - DwVfpRegister double_scratch2 = ToDoubleRegister(instr->temp3());
|
| + Register scratch3 = ToRegister(instr->TempAt(1));
|
| + DwVfpRegister double_scratch2 = ToDoubleRegister(instr->TempAt(2));
|
| ASSERT(!scratch3.is(input_reg) &&
|
| !scratch3.is(scratch1) &&
|
| !scratch3.is(scratch2));
|
| @@ -4666,7 +4662,7 @@ void LCodeGen::DoTaggedToI(LTaggedToI* instr) {
|
| LTaggedToI* instr_;
|
| };
|
|
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| ASSERT(input->IsRegister());
|
| ASSERT(input->Equals(instr->result()));
|
|
|
| @@ -4685,7 +4681,7 @@ void LCodeGen::DoTaggedToI(LTaggedToI* instr) {
|
|
|
|
|
| void LCodeGen::DoNumberUntagD(LNumberUntagD* instr) {
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| ASSERT(input->IsRegister());
|
| LOperand* result = instr->result();
|
| ASSERT(result->IsDoubleRegister());
|
| @@ -4703,14 +4699,14 @@ void LCodeGen::DoNumberUntagD(LNumberUntagD* instr) {
|
| void LCodeGen::DoDoubleToI(LDoubleToI* instr) {
|
| Register result_reg = ToRegister(instr->result());
|
| Register scratch1 = scratch0();
|
| - Register scratch2 = ToRegister(instr->temp());
|
| - DwVfpRegister double_input = ToDoubleRegister(instr->value());
|
| + Register scratch2 = ToRegister(instr->TempAt(0));
|
| + DwVfpRegister double_input = ToDoubleRegister(instr->InputAt(0));
|
| SwVfpRegister single_scratch = double_scratch0().low();
|
|
|
| Label done;
|
|
|
| if (instr->truncating()) {
|
| - Register scratch3 = ToRegister(instr->temp2());
|
| + Register scratch3 = ToRegister(instr->TempAt(1));
|
| __ EmitECMATruncate(result_reg,
|
| double_input,
|
| single_scratch,
|
| @@ -4736,21 +4732,21 @@ void LCodeGen::DoDoubleToI(LDoubleToI* instr) {
|
|
|
|
|
| void LCodeGen::DoCheckSmi(LCheckSmi* instr) {
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| __ tst(ToRegister(input), Operand(kSmiTagMask));
|
| DeoptimizeIf(ne, instr->environment());
|
| }
|
|
|
|
|
| void LCodeGen::DoCheckNonSmi(LCheckNonSmi* instr) {
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| __ tst(ToRegister(input), Operand(kSmiTagMask));
|
| DeoptimizeIf(eq, instr->environment());
|
| }
|
|
|
|
|
| void LCodeGen::DoCheckInstanceType(LCheckInstanceType* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| Register scratch = scratch0();
|
|
|
| __ ldr(scratch, FieldMemOperand(input, HeapObject::kMapOffset));
|
| @@ -4823,7 +4819,7 @@ void LCodeGen::DoCheckMapCommon(Register reg,
|
|
|
| void LCodeGen::DoCheckMaps(LCheckMaps* instr) {
|
| Register scratch = scratch0();
|
| - LOperand* input = instr->value();
|
| + LOperand* input = instr->InputAt(0);
|
| ASSERT(input->IsRegister());
|
| Register reg = ToRegister(input);
|
|
|
| @@ -4843,7 +4839,7 @@ void LCodeGen::DoCheckMaps(LCheckMaps* instr) {
|
| void LCodeGen::DoClampDToUint8(LClampDToUint8* instr) {
|
| DoubleRegister value_reg = ToDoubleRegister(instr->unclamped());
|
| Register result_reg = ToRegister(instr->result());
|
| - DoubleRegister temp_reg = ToDoubleRegister(instr->temp());
|
| + DoubleRegister temp_reg = ToDoubleRegister(instr->TempAt(0));
|
| __ ClampDoubleToUint8(result_reg, value_reg, temp_reg);
|
| }
|
|
|
| @@ -4859,7 +4855,7 @@ void LCodeGen::DoClampTToUint8(LClampTToUint8* instr) {
|
| Register scratch = scratch0();
|
| Register input_reg = ToRegister(instr->unclamped());
|
| Register result_reg = ToRegister(instr->result());
|
| - DoubleRegister temp_reg = ToDoubleRegister(instr->temp());
|
| + DoubleRegister temp_reg = ToDoubleRegister(instr->TempAt(0));
|
| Label is_smi, done, heap_number;
|
|
|
| // Both smi and heap number cases are handled.
|
| @@ -4893,8 +4889,8 @@ void LCodeGen::DoClampTToUint8(LClampTToUint8* instr) {
|
|
|
|
|
| void LCodeGen::DoCheckPrototypeMaps(LCheckPrototypeMaps* instr) {
|
| - Register temp1 = ToRegister(instr->temp());
|
| - Register temp2 = ToRegister(instr->temp2());
|
| + Register temp1 = ToRegister(instr->TempAt(0));
|
| + Register temp2 = ToRegister(instr->TempAt(1));
|
|
|
| Handle<JSObject> holder = instr->holder();
|
| Handle<JSObject> current_prototype = instr->prototype();
|
| @@ -4936,8 +4932,8 @@ void LCodeGen::DoAllocateObject(LAllocateObject* instr) {
|
| new(zone()) DeferredAllocateObject(this, instr);
|
|
|
| Register result = ToRegister(instr->result());
|
| - Register scratch = ToRegister(instr->temp());
|
| - Register scratch2 = ToRegister(instr->temp2());
|
| + Register scratch = ToRegister(instr->TempAt(0));
|
| + Register scratch2 = ToRegister(instr->TempAt(1));
|
| Handle<JSFunction> constructor = instr->hydrogen()->constructor();
|
| Handle<Map> initial_map(constructor->initial_map());
|
| int instance_size = initial_map->instance_size();
|
| @@ -5229,7 +5225,7 @@ void LCodeGen::DoObjectLiteral(LObjectLiteral* instr) {
|
|
|
|
|
| void LCodeGen::DoToFastProperties(LToFastProperties* instr) {
|
| - ASSERT(ToRegister(instr->value()).is(r0));
|
| + ASSERT(ToRegister(instr->InputAt(0)).is(r0));
|
| __ push(r0);
|
| CallRuntime(Runtime::kToFastProperties, 1, instr);
|
| }
|
| @@ -5310,14 +5306,14 @@ void LCodeGen::DoFunctionLiteral(LFunctionLiteral* instr) {
|
|
|
|
|
| void LCodeGen::DoTypeof(LTypeof* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| __ push(input);
|
| CallRuntime(Runtime::kTypeof, 1, instr);
|
| }
|
|
|
|
|
| void LCodeGen::DoTypeofIsAndBranch(LTypeofIsAndBranch* instr) {
|
| - Register input = ToRegister(instr->value());
|
| + Register input = ToRegister(instr->InputAt(0));
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
| Label* true_label = chunk_->GetAssemblyLabel(true_block);
|
| @@ -5407,7 +5403,7 @@ Condition LCodeGen::EmitTypeofIs(Label* true_label,
|
|
|
|
|
| void LCodeGen::DoIsConstructCallAndBranch(LIsConstructCallAndBranch* instr) {
|
| - Register temp1 = ToRegister(instr->temp());
|
| + Register temp1 = ToRegister(instr->TempAt(0));
|
| int true_block = chunk_->LookupDestination(instr->true_block_id());
|
| int false_block = chunk_->LookupDestination(instr->false_block_id());
|
|
|
|
|