| 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 #if V8_TARGET_ARCH_X87 | 5 #if V8_TARGET_ARCH_X87 |
| 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 1797 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1808 __ RecordWriteField(ebx, JSGeneratorObject::kInputOffset, ecx, edx, | 1808 __ RecordWriteField(ebx, JSGeneratorObject::kInputOffset, ecx, edx, |
| 1809 kDontSaveFPRegs); | 1809 kDontSaveFPRegs); |
| 1810 | 1810 |
| 1811 // Load suspended function and context. | 1811 // Load suspended function and context. |
| 1812 __ mov(esi, FieldOperand(ebx, JSGeneratorObject::kContextOffset)); | 1812 __ mov(esi, FieldOperand(ebx, JSGeneratorObject::kContextOffset)); |
| 1813 __ mov(edi, FieldOperand(ebx, JSGeneratorObject::kFunctionOffset)); | 1813 __ mov(edi, FieldOperand(ebx, JSGeneratorObject::kFunctionOffset)); |
| 1814 | 1814 |
| 1815 // Push receiver. | 1815 // Push receiver. |
| 1816 __ push(FieldOperand(ebx, JSGeneratorObject::kReceiverOffset)); | 1816 __ push(FieldOperand(ebx, JSGeneratorObject::kReceiverOffset)); |
| 1817 | 1817 |
| 1818 // Push holes for arguments to generator function. | 1818 // Push holes for arguments to generator function. Since the parser forced |
| 1819 // context allocation for any variables in generators, the actual argument |
| 1820 // values have already been copied into the context and these dummy values |
| 1821 // will never be used. |
| 1819 __ mov(edx, FieldOperand(edi, JSFunction::kSharedFunctionInfoOffset)); | 1822 __ mov(edx, FieldOperand(edi, JSFunction::kSharedFunctionInfoOffset)); |
| 1820 __ mov(edx, | 1823 __ mov(edx, |
| 1821 FieldOperand(edx, SharedFunctionInfo::kFormalParameterCountOffset)); | 1824 FieldOperand(edx, SharedFunctionInfo::kFormalParameterCountOffset)); |
| 1822 __ mov(ecx, isolate()->factory()->the_hole_value()); | 1825 __ mov(ecx, isolate()->factory()->the_hole_value()); |
| 1823 Label push_argument_holes, push_frame; | 1826 Label push_argument_holes, push_frame; |
| 1824 __ bind(&push_argument_holes); | 1827 __ bind(&push_argument_holes); |
| 1825 __ sub(edx, Immediate(Smi::FromInt(1))); | 1828 __ sub(edx, Immediate(Smi::FromInt(1))); |
| 1826 __ j(carry, &push_frame); | 1829 __ j(carry, &push_frame); |
| 1827 __ push(ecx); | 1830 __ push(ecx); |
| 1828 __ jmp(&push_argument_holes); | 1831 __ jmp(&push_argument_holes); |
| (...skipping 2160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3989 isolate->builtins()->OnStackReplacement()->entry(), | 3992 isolate->builtins()->OnStackReplacement()->entry(), |
| 3990 Assembler::target_address_at(call_target_address, unoptimized_code)); | 3993 Assembler::target_address_at(call_target_address, unoptimized_code)); |
| 3991 return ON_STACK_REPLACEMENT; | 3994 return ON_STACK_REPLACEMENT; |
| 3992 } | 3995 } |
| 3993 | 3996 |
| 3994 | 3997 |
| 3995 } // namespace internal | 3998 } // namespace internal |
| 3996 } // namespace v8 | 3999 } // namespace v8 |
| 3997 | 4000 |
| 3998 #endif // V8_TARGET_ARCH_X87 | 4001 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |