| 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 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 | 259 |
| 260 int num_parameters = info->scope()->num_parameters(); | 260 int num_parameters = info->scope()->num_parameters(); |
| 261 int offset = num_parameters * kPointerSize; | 261 int offset = num_parameters * kPointerSize; |
| 262 | 262 |
| 263 __ mov(RestParamAccessDescriptor::parameter_count(), | 263 __ mov(RestParamAccessDescriptor::parameter_count(), |
| 264 Immediate(Smi::FromInt(num_parameters))); | 264 Immediate(Smi::FromInt(num_parameters))); |
| 265 __ lea(RestParamAccessDescriptor::parameter_pointer(), | 265 __ lea(RestParamAccessDescriptor::parameter_pointer(), |
| 266 Operand(ebp, StandardFrameConstants::kCallerSPOffset + offset)); | 266 Operand(ebp, StandardFrameConstants::kCallerSPOffset + offset)); |
| 267 __ mov(RestParamAccessDescriptor::rest_parameter_index(), | 267 __ mov(RestParamAccessDescriptor::rest_parameter_index(), |
| 268 Immediate(Smi::FromInt(rest_index))); | 268 Immediate(Smi::FromInt(rest_index))); |
| 269 __ mov(RestParamAccessDescriptor::language_mode(), | |
| 270 Immediate(Smi::FromInt(language_mode()))); | |
| 271 function_in_register = false; | 269 function_in_register = false; |
| 272 | 270 |
| 273 RestParamAccessStub stub(isolate()); | 271 RestParamAccessStub stub(isolate()); |
| 274 __ CallStub(&stub); | 272 __ CallStub(&stub); |
| 275 SetVar(rest_param, eax, ebx, edx); | 273 SetVar(rest_param, eax, ebx, edx); |
| 276 } | 274 } |
| 277 | 275 |
| 278 Variable* arguments = scope()->arguments(); | 276 Variable* arguments = scope()->arguments(); |
| 279 if (arguments != NULL) { | 277 if (arguments != NULL) { |
| 280 // Function uses arguments object. | 278 // Function uses arguments object. |
| (...skipping 4497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4778 Assembler::target_address_at(call_target_address, | 4776 Assembler::target_address_at(call_target_address, |
| 4779 unoptimized_code)); | 4777 unoptimized_code)); |
| 4780 return OSR_AFTER_STACK_CHECK; | 4778 return OSR_AFTER_STACK_CHECK; |
| 4781 } | 4779 } |
| 4782 | 4780 |
| 4783 | 4781 |
| 4784 } // namespace internal | 4782 } // namespace internal |
| 4785 } // namespace v8 | 4783 } // namespace v8 |
| 4786 | 4784 |
| 4787 #endif // V8_TARGET_ARCH_X87 | 4785 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |