| Index: src/full-codegen/x87/full-codegen-x87.cc
|
| diff --git a/src/full-codegen/x87/full-codegen-x87.cc b/src/full-codegen/x87/full-codegen-x87.cc
|
| index 26027c3a0b589d2613223d3ccfcd8fc47ebe4b7e..95167516b8e77b71a162864fdd67323ad5da61d1 100644
|
| --- a/src/full-codegen/x87/full-codegen-x87.cc
|
| +++ b/src/full-codegen/x87/full-codegen-x87.cc
|
| @@ -1669,56 +1669,8 @@ void FullCodeGenerator::VisitAssignment(Assignment* expr) {
|
|
|
|
|
| void FullCodeGenerator::VisitYield(Yield* expr) {
|
| - Comment cmnt(masm_, "[ Yield");
|
| - SetExpressionPosition(expr);
|
| -
|
| - // Evaluate yielded value first; the initial iterator definition depends on
|
| - // this. It stays on the stack while we update the iterator.
|
| - VisitForStackValue(expr->expression());
|
| -
|
| - Label suspend, continuation, post_runtime, resume, exception;
|
| -
|
| - __ jmp(&suspend);
|
| - __ bind(&continuation);
|
| - // When we arrive here, eax holds the generator object.
|
| - __ RecordGeneratorContinuation();
|
| - __ mov(ebx, FieldOperand(eax, JSGeneratorObject::kResumeModeOffset));
|
| - __ mov(eax, FieldOperand(eax, JSGeneratorObject::kInputOrDebugPosOffset));
|
| - STATIC_ASSERT(JSGeneratorObject::kNext < JSGeneratorObject::kReturn);
|
| - STATIC_ASSERT(JSGeneratorObject::kThrow > JSGeneratorObject::kReturn);
|
| - __ cmp(ebx, Immediate(Smi::FromInt(JSGeneratorObject::kReturn)));
|
| - __ j(less, &resume);
|
| - __ Push(result_register());
|
| - __ j(greater, &exception);
|
| - EmitCreateIteratorResult(true);
|
| - EmitUnwindAndReturn();
|
| -
|
| - __ bind(&exception);
|
| - __ CallRuntime(expr->rethrow_on_exception() ? Runtime::kReThrow
|
| - : Runtime::kThrow);
|
| -
|
| - __ bind(&suspend);
|
| - OperandStackDepthIncrement(1); // Not popped on this path.
|
| - VisitForAccumulatorValue(expr->generator_object());
|
| - DCHECK(continuation.pos() > 0 && Smi::IsValid(continuation.pos()));
|
| - __ mov(FieldOperand(eax, JSGeneratorObject::kContinuationOffset),
|
| - Immediate(Smi::FromInt(continuation.pos())));
|
| - __ mov(FieldOperand(eax, JSGeneratorObject::kContextOffset), esi);
|
| - __ mov(ecx, esi);
|
| - __ RecordWriteField(eax, JSGeneratorObject::kContextOffset, ecx, edx,
|
| - kDontSaveFPRegs);
|
| - __ lea(ebx, Operand(ebp, StandardFrameConstants::kExpressionsOffset));
|
| - __ cmp(esp, ebx);
|
| - __ j(equal, &post_runtime);
|
| - __ push(eax); // generator object
|
| - __ CallRuntime(Runtime::kSuspendJSGeneratorObject, 1);
|
| - RestoreContext();
|
| - __ bind(&post_runtime);
|
| - PopOperand(result_register());
|
| - EmitReturnSequence();
|
| -
|
| - __ bind(&resume);
|
| - context()->Plug(result_register());
|
| + // Resumable functions are not supported.
|
| + UNREACHABLE();
|
| }
|
|
|
| void FullCodeGenerator::PushOperand(MemOperand operand) {
|
|
|