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_X64 | 5 #if V8_TARGET_ARCH_X64 |
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 1364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1375 __ Push(constant_properties); | 1375 __ Push(constant_properties); |
1376 __ Push(Smi::FromInt(flags)); | 1376 __ Push(Smi::FromInt(flags)); |
1377 __ CallRuntime(Runtime::kCreateObjectLiteral); | 1377 __ CallRuntime(Runtime::kCreateObjectLiteral); |
1378 } else { | 1378 } else { |
1379 __ movp(rax, Operand(rbp, JavaScriptFrameConstants::kFunctionOffset)); | 1379 __ movp(rax, Operand(rbp, JavaScriptFrameConstants::kFunctionOffset)); |
1380 __ Move(rbx, Smi::FromInt(expr->literal_index())); | 1380 __ Move(rbx, Smi::FromInt(expr->literal_index())); |
1381 __ Move(rcx, constant_properties); | 1381 __ Move(rcx, constant_properties); |
1382 __ Move(rdx, Smi::FromInt(flags)); | 1382 __ Move(rdx, Smi::FromInt(flags)); |
1383 FastCloneShallowObjectStub stub(isolate(), expr->properties_count()); | 1383 FastCloneShallowObjectStub stub(isolate(), expr->properties_count()); |
1384 __ CallStub(&stub); | 1384 __ CallStub(&stub); |
1385 __ movp(rsi, Operand(rbp, StandardFrameConstants::kContextOffset)); | |
1386 } | 1385 } |
1387 PrepareForBailoutForId(expr->CreateLiteralId(), TOS_REG); | 1386 PrepareForBailoutForId(expr->CreateLiteralId(), TOS_REG); |
1388 | 1387 |
1389 // If result_saved is true the result is on top of the stack. If | 1388 // If result_saved is true the result is on top of the stack. If |
1390 // result_saved is false the result is in rax. | 1389 // result_saved is false the result is in rax. |
1391 bool result_saved = false; | 1390 bool result_saved = false; |
1392 | 1391 |
1393 AccessorTable accessor_table(zone()); | 1392 AccessorTable accessor_table(zone()); |
1394 int property_index = 0; | 1393 int property_index = 0; |
1395 for (; property_index < expr->properties()->length(); property_index++) { | 1394 for (; property_index < expr->properties()->length(); property_index++) { |
(...skipping 2484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3880 DCHECK_EQ( | 3879 DCHECK_EQ( |
3881 isolate->builtins()->OnStackReplacement()->entry(), | 3880 isolate->builtins()->OnStackReplacement()->entry(), |
3882 Assembler::target_address_at(call_target_address, unoptimized_code)); | 3881 Assembler::target_address_at(call_target_address, unoptimized_code)); |
3883 return ON_STACK_REPLACEMENT; | 3882 return ON_STACK_REPLACEMENT; |
3884 } | 3883 } |
3885 | 3884 |
3886 } // namespace internal | 3885 } // namespace internal |
3887 } // namespace v8 | 3886 } // namespace v8 |
3888 | 3887 |
3889 #endif // V8_TARGET_ARCH_X64 | 3888 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |