OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 #if V8_TARGET_ARCH_S390 | 5 #if V8_TARGET_ARCH_S390 |
6 | 6 |
7 #include "src/ast/scopes.h" | 7 #include "src/ast/scopes.h" |
8 #include "src/code-factory.h" | 8 #include "src/code-factory.h" |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 1726 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1737 // this. It stays on the stack while we update the iterator. | 1737 // this. It stays on the stack while we update the iterator. |
1738 VisitForStackValue(expr->expression()); | 1738 VisitForStackValue(expr->expression()); |
1739 | 1739 |
1740 Label suspend, continuation, post_runtime, resume, exception; | 1740 Label suspend, continuation, post_runtime, resume, exception; |
1741 | 1741 |
1742 __ b(&suspend); | 1742 __ b(&suspend); |
1743 __ bind(&continuation); | 1743 __ bind(&continuation); |
1744 // When we arrive here, r2 holds the generator object. | 1744 // When we arrive here, r2 holds the generator object. |
1745 __ RecordGeneratorContinuation(); | 1745 __ RecordGeneratorContinuation(); |
1746 __ LoadP(r3, FieldMemOperand(r2, JSGeneratorObject::kResumeModeOffset)); | 1746 __ LoadP(r3, FieldMemOperand(r2, JSGeneratorObject::kResumeModeOffset)); |
1747 __ LoadP(r2, FieldMemOperand(r2, JSGeneratorObject::kInputOffset)); | 1747 __ LoadP(r2, FieldMemOperand(r2, JSGeneratorObject::kInputOrDebugPosOffset)); |
1748 STATIC_ASSERT(JSGeneratorObject::kNext < JSGeneratorObject::kReturn); | 1748 STATIC_ASSERT(JSGeneratorObject::kNext < JSGeneratorObject::kReturn); |
1749 STATIC_ASSERT(JSGeneratorObject::kThrow > JSGeneratorObject::kReturn); | 1749 STATIC_ASSERT(JSGeneratorObject::kThrow > JSGeneratorObject::kReturn); |
1750 __ CmpSmiLiteral(r3, Smi::FromInt(JSGeneratorObject::kReturn), r0); | 1750 __ CmpSmiLiteral(r3, Smi::FromInt(JSGeneratorObject::kReturn), r0); |
1751 __ blt(&resume); | 1751 __ blt(&resume); |
1752 __ Push(result_register()); | 1752 __ Push(result_register()); |
1753 __ bgt(&exception); | 1753 __ bgt(&exception); |
1754 EmitCreateIteratorResult(true); | 1754 EmitCreateIteratorResult(true); |
1755 EmitUnwindAndReturn(); | 1755 EmitUnwindAndReturn(); |
1756 | 1756 |
1757 __ bind(&exception); | 1757 __ bind(&exception); |
(...skipping 1936 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3694 DCHECK(kOSRBranchInstruction == br_instr); | 3694 DCHECK(kOSRBranchInstruction == br_instr); |
3695 | 3695 |
3696 DCHECK(interrupt_address == | 3696 DCHECK(interrupt_address == |
3697 isolate->builtins()->OnStackReplacement()->entry()); | 3697 isolate->builtins()->OnStackReplacement()->entry()); |
3698 return ON_STACK_REPLACEMENT; | 3698 return ON_STACK_REPLACEMENT; |
3699 } | 3699 } |
3700 | 3700 |
3701 } // namespace internal | 3701 } // namespace internal |
3702 } // namespace v8 | 3702 } // namespace v8 |
3703 #endif // V8_TARGET_ARCH_S390 | 3703 #endif // V8_TARGET_ARCH_S390 |
OLD | NEW |