| 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/full-codegen/full-codegen.h" | 7 #include "src/full-codegen/full-codegen.h" |
| 8 #include "src/ast/compile-time-value.h" | 8 #include "src/ast/compile-time-value.h" |
| 9 #include "src/ast/scopes.h" | 9 #include "src/ast/scopes.h" |
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
| (...skipping 1180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1191 DCHECK(!property->is_computed_name()); | 1191 DCHECK(!property->is_computed_name()); |
| 1192 if (property->IsCompileTimeValue()) continue; | 1192 if (property->IsCompileTimeValue()) continue; |
| 1193 | 1193 |
| 1194 Literal* key = property->key()->AsLiteral(); | 1194 Literal* key = property->key()->AsLiteral(); |
| 1195 Expression* value = property->value(); | 1195 Expression* value = property->value(); |
| 1196 if (!result_saved) { | 1196 if (!result_saved) { |
| 1197 PushOperand(rax); // Save result on the stack | 1197 PushOperand(rax); // Save result on the stack |
| 1198 result_saved = true; | 1198 result_saved = true; |
| 1199 } | 1199 } |
| 1200 switch (property->kind()) { | 1200 switch (property->kind()) { |
| 1201 case ObjectLiteral::Property::SPREAD: |
| 1201 case ObjectLiteral::Property::CONSTANT: | 1202 case ObjectLiteral::Property::CONSTANT: |
| 1202 UNREACHABLE(); | 1203 UNREACHABLE(); |
| 1203 case ObjectLiteral::Property::MATERIALIZED_LITERAL: | 1204 case ObjectLiteral::Property::MATERIALIZED_LITERAL: |
| 1204 DCHECK(!CompileTimeValue::IsCompileTimeValue(value)); | 1205 DCHECK(!CompileTimeValue::IsCompileTimeValue(value)); |
| 1205 // Fall through. | 1206 // Fall through. |
| 1206 case ObjectLiteral::Property::COMPUTED: | 1207 case ObjectLiteral::Property::COMPUTED: |
| 1207 // It is safe to use [[Put]] here because the boilerplate already | 1208 // It is safe to use [[Put]] here because the boilerplate already |
| 1208 // contains computed properties with an uninitialized value. | 1209 // contains computed properties with an uninitialized value. |
| 1209 if (key->IsStringLiteral()) { | 1210 if (key->IsStringLiteral()) { |
| 1210 DCHECK(key->IsPropertyName()); | 1211 DCHECK(key->IsPropertyName()); |
| (...skipping 1560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2771 DCHECK_EQ( | 2772 DCHECK_EQ( |
| 2772 isolate->builtins()->OnStackReplacement()->entry(), | 2773 isolate->builtins()->OnStackReplacement()->entry(), |
| 2773 Assembler::target_address_at(call_target_address, unoptimized_code)); | 2774 Assembler::target_address_at(call_target_address, unoptimized_code)); |
| 2774 return ON_STACK_REPLACEMENT; | 2775 return ON_STACK_REPLACEMENT; |
| 2775 } | 2776 } |
| 2776 | 2777 |
| 2777 } // namespace internal | 2778 } // namespace internal |
| 2778 } // namespace v8 | 2779 } // namespace v8 |
| 2779 | 2780 |
| 2780 #endif // V8_TARGET_ARCH_X64 | 2781 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |