OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
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 4366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4377 __ Bind(&post_runtime); | 4377 __ Bind(&post_runtime); |
4378 __ Pop(result_register()); | 4378 __ Pop(result_register()); |
4379 EmitReturnSequence(); | 4379 EmitReturnSequence(); |
4380 | 4380 |
4381 __ Bind(&resume); | 4381 __ Bind(&resume); |
4382 context()->Plug(result_register()); | 4382 context()->Plug(result_register()); |
4383 break; | 4383 break; |
4384 } | 4384 } |
4385 | 4385 |
4386 case Yield::kFinal: { | 4386 case Yield::kFinal: { |
4387 VisitForAccumulatorValue(expr->generator_object()); | |
4388 __ Mov(x1, Smi::FromInt(JSGeneratorObject::kGeneratorClosed)); | |
4389 __ Str(x1, FieldMemOperand(result_register(), | |
4390 JSGeneratorObject::kContinuationOffset)); | |
4391 // Pop value from top-of-stack slot, box result into result register. | 4387 // Pop value from top-of-stack slot, box result into result register. |
4392 EmitCreateIteratorResult(true); | 4388 EmitCreateIteratorResult(true); |
4393 EmitUnwindBeforeReturn(); | 4389 EmitUnwindBeforeReturn(); |
4394 EmitReturnSequence(); | 4390 EmitReturnSequence(); |
4395 break; | 4391 break; |
4396 } | 4392 } |
4397 | 4393 |
4398 case Yield::kDelegating: { | 4394 case Yield::kDelegating: { |
4399 VisitForStackValue(expr->generator_object()); | 4395 VisitForStackValue(expr->generator_object()); |
4400 | 4396 |
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4836 } | 4832 } |
4837 | 4833 |
4838 return INTERRUPT; | 4834 return INTERRUPT; |
4839 } | 4835 } |
4840 | 4836 |
4841 | 4837 |
4842 } // namespace internal | 4838 } // namespace internal |
4843 } // namespace v8 | 4839 } // namespace v8 |
4844 | 4840 |
4845 #endif // V8_TARGET_ARCH_ARM64 | 4841 #endif // V8_TARGET_ARCH_ARM64 |
OLD | NEW |