OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <sstream> | 5 #include <sstream> |
6 | 6 |
7 #include "src/v8.h" | 7 #include "src/v8.h" |
8 | 8 |
9 #include "src/hydrogen-osr.h" | 9 #include "src/hydrogen-osr.h" |
10 #include "src/lithium-inl.h" | 10 #include "src/lithium-inl.h" |
(...skipping 1627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1638 DCHECK(instr->right()->representation().Equals(instr->representation())); | 1638 DCHECK(instr->right()->representation().Equals(instr->representation())); |
1639 LOperand* left = UseRegisterAtStart(instr->BetterLeftOperand()); | 1639 LOperand* left = UseRegisterAtStart(instr->BetterLeftOperand()); |
1640 LOperand* right = UseOrConstantAtStart(instr->BetterRightOperand()); | 1640 LOperand* right = UseOrConstantAtStart(instr->BetterRightOperand()); |
1641 LAddI* add = new (zone()) LAddI(left, right); | 1641 LAddI* add = new (zone()) LAddI(left, right); |
1642 LInstruction* result = DefineAsRegister(add); | 1642 LInstruction* result = DefineAsRegister(add); |
1643 if (instr->CheckFlag(HValue::kCanOverflow)) { | 1643 if (instr->CheckFlag(HValue::kCanOverflow)) { |
1644 result = AssignEnvironment(result); | 1644 result = AssignEnvironment(result); |
1645 } | 1645 } |
1646 return result; | 1646 return result; |
1647 } else if (instr->representation().IsExternal()) { | 1647 } else if (instr->representation().IsExternal()) { |
1648 DCHECK(instr->left()->representation().IsExternal()); | 1648 DCHECK(instr->IsConsistentExternalRepresentation()); |
1649 DCHECK(instr->right()->representation().IsInteger32()); | |
1650 DCHECK(!instr->CheckFlag(HValue::kCanOverflow)); | 1649 DCHECK(!instr->CheckFlag(HValue::kCanOverflow)); |
1651 LOperand* left = UseRegisterAtStart(instr->left()); | 1650 LOperand* left = UseRegisterAtStart(instr->left()); |
1652 LOperand* right = UseOrConstantAtStart(instr->right()); | 1651 LOperand* right = UseOrConstantAtStart(instr->right()); |
1653 LAddI* add = new (zone()) LAddI(left, right); | 1652 LAddI* add = new (zone()) LAddI(left, right); |
1654 LInstruction* result = DefineAsRegister(add); | 1653 LInstruction* result = DefineAsRegister(add); |
1655 return result; | 1654 return result; |
1656 } else if (instr->representation().IsDouble()) { | 1655 } else if (instr->representation().IsDouble()) { |
1657 return DoArithmeticD(Token::ADD, instr); | 1656 return DoArithmeticD(Token::ADD, instr); |
1658 } else { | 1657 } else { |
1659 return DoArithmeticT(Token::ADD, instr); | 1658 return DoArithmeticT(Token::ADD, instr); |
(...skipping 1014 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2674 LInstruction* LChunkBuilder::DoAllocateBlockContext( | 2673 LInstruction* LChunkBuilder::DoAllocateBlockContext( |
2675 HAllocateBlockContext* instr) { | 2674 HAllocateBlockContext* instr) { |
2676 LOperand* context = UseFixed(instr->context(), cp); | 2675 LOperand* context = UseFixed(instr->context(), cp); |
2677 LOperand* function = UseRegisterAtStart(instr->function()); | 2676 LOperand* function = UseRegisterAtStart(instr->function()); |
2678 LAllocateBlockContext* result = | 2677 LAllocateBlockContext* result = |
2679 new (zone()) LAllocateBlockContext(context, function); | 2678 new (zone()) LAllocateBlockContext(context, function); |
2680 return MarkAsCall(DefineFixed(result, cp), instr); | 2679 return MarkAsCall(DefineFixed(result, cp), instr); |
2681 } | 2680 } |
2682 } // namespace internal | 2681 } // namespace internal |
2683 } // namespace v8 | 2682 } // namespace v8 |
OLD | NEW |