OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/hydrogen-osr.h" | 7 #include "src/hydrogen-osr.h" |
8 #include "src/lithium-allocator-inl.h" | 8 #include "src/lithium-allocator-inl.h" |
9 #include "src/mips/lithium-codegen-mips.h" | 9 #include "src/mips/lithium-codegen-mips.h" |
10 #include "src/mips/lithium-mips.h" | 10 #include "src/mips/lithium-mips.h" |
(...skipping 1400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1411 | 1411 |
1412 | 1412 |
1413 LInstruction* LChunkBuilder::DoModByPowerOf2I(HMod* instr) { | 1413 LInstruction* LChunkBuilder::DoModByPowerOf2I(HMod* instr) { |
1414 ASSERT(instr->representation().IsSmiOrInteger32()); | 1414 ASSERT(instr->representation().IsSmiOrInteger32()); |
1415 ASSERT(instr->left()->representation().Equals(instr->representation())); | 1415 ASSERT(instr->left()->representation().Equals(instr->representation())); |
1416 ASSERT(instr->right()->representation().Equals(instr->representation())); | 1416 ASSERT(instr->right()->representation().Equals(instr->representation())); |
1417 LOperand* dividend = UseRegisterAtStart(instr->left()); | 1417 LOperand* dividend = UseRegisterAtStart(instr->left()); |
1418 int32_t divisor = instr->right()->GetInteger32Constant(); | 1418 int32_t divisor = instr->right()->GetInteger32Constant(); |
1419 LInstruction* result = DefineSameAsFirst(new(zone()) LModByPowerOf2I( | 1419 LInstruction* result = DefineSameAsFirst(new(zone()) LModByPowerOf2I( |
1420 dividend, divisor)); | 1420 dividend, divisor)); |
1421 if (instr->CheckFlag(HValue::kBailoutOnMinusZero)) { | 1421 if (instr->CheckFlag(HValue::kLeftCanBeNegative) && |
| 1422 instr->CheckFlag(HValue::kBailoutOnMinusZero)) { |
1422 result = AssignEnvironment(result); | 1423 result = AssignEnvironment(result); |
1423 } | 1424 } |
1424 return result; | 1425 return result; |
1425 } | 1426 } |
1426 | 1427 |
1427 | 1428 |
1428 LInstruction* LChunkBuilder::DoModByConstI(HMod* instr) { | 1429 LInstruction* LChunkBuilder::DoModByConstI(HMod* instr) { |
1429 ASSERT(instr->representation().IsSmiOrInteger32()); | 1430 ASSERT(instr->representation().IsSmiOrInteger32()); |
1430 ASSERT(instr->left()->representation().Equals(instr->representation())); | 1431 ASSERT(instr->left()->representation().Equals(instr->representation())); |
1431 ASSERT(instr->right()->representation().Equals(instr->representation())); | 1432 ASSERT(instr->right()->representation().Equals(instr->representation())); |
(...skipping 1135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2567 LInstruction* LChunkBuilder::DoAllocateBlockContext( | 2568 LInstruction* LChunkBuilder::DoAllocateBlockContext( |
2568 HAllocateBlockContext* instr) { | 2569 HAllocateBlockContext* instr) { |
2569 LOperand* context = UseFixed(instr->context(), cp); | 2570 LOperand* context = UseFixed(instr->context(), cp); |
2570 LOperand* function = UseRegisterAtStart(instr->function()); | 2571 LOperand* function = UseRegisterAtStart(instr->function()); |
2571 LAllocateBlockContext* result = | 2572 LAllocateBlockContext* result = |
2572 new(zone()) LAllocateBlockContext(context, function); | 2573 new(zone()) LAllocateBlockContext(context, function); |
2573 return MarkAsCall(DefineFixed(result, cp), instr); | 2574 return MarkAsCall(DefineFixed(result, cp), instr); |
2574 } | 2575 } |
2575 | 2576 |
2576 } } // namespace v8::internal | 2577 } } // namespace v8::internal |
OLD | NEW |