| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
| 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 1620 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1631 EmitSetHomeObject(value, 2, property->GetSlot()); | 1631 EmitSetHomeObject(value, 2, property->GetSlot()); |
| 1632 } | 1632 } |
| 1633 | 1633 |
| 1634 switch (property->kind()) { | 1634 switch (property->kind()) { |
| 1635 case ObjectLiteral::Property::CONSTANT: | 1635 case ObjectLiteral::Property::CONSTANT: |
| 1636 case ObjectLiteral::Property::MATERIALIZED_LITERAL: | 1636 case ObjectLiteral::Property::MATERIALIZED_LITERAL: |
| 1637 case ObjectLiteral::Property::COMPUTED: | 1637 case ObjectLiteral::Property::COMPUTED: |
| 1638 if (property->emit_store()) { | 1638 if (property->emit_store()) { |
| 1639 __ Mov(x0, Smi::FromInt(NONE)); | 1639 __ Mov(x0, Smi::FromInt(NONE)); |
| 1640 __ Push(x0); | 1640 __ Push(x0); |
| 1641 __ CallRuntime(Runtime::kDefineDataPropertyUnchecked); | 1641 __ Push(Smi::FromInt(property->NeedsSetFunctionName())); |
| 1642 __ CallRuntime(Runtime::kDefineDataPropertyInLiteral); |
| 1642 } else { | 1643 } else { |
| 1643 __ Drop(3); | 1644 __ Drop(3); |
| 1644 } | 1645 } |
| 1645 break; | 1646 break; |
| 1646 | 1647 |
| 1647 case ObjectLiteral::Property::PROTOTYPE: | 1648 case ObjectLiteral::Property::PROTOTYPE: |
| 1648 UNREACHABLE(); | 1649 UNREACHABLE(); |
| 1649 break; | 1650 break; |
| 1650 | 1651 |
| 1651 case ObjectLiteral::Property::GETTER: | 1652 case ObjectLiteral::Property::GETTER: |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2097 if (NeedsHomeObject(value)) { | 2098 if (NeedsHomeObject(value)) { |
| 2098 EmitSetHomeObject(value, 2, property->GetSlot()); | 2099 EmitSetHomeObject(value, 2, property->GetSlot()); |
| 2099 } | 2100 } |
| 2100 | 2101 |
| 2101 switch (property->kind()) { | 2102 switch (property->kind()) { |
| 2102 case ObjectLiteral::Property::CONSTANT: | 2103 case ObjectLiteral::Property::CONSTANT: |
| 2103 case ObjectLiteral::Property::MATERIALIZED_LITERAL: | 2104 case ObjectLiteral::Property::MATERIALIZED_LITERAL: |
| 2104 case ObjectLiteral::Property::PROTOTYPE: | 2105 case ObjectLiteral::Property::PROTOTYPE: |
| 2105 UNREACHABLE(); | 2106 UNREACHABLE(); |
| 2106 case ObjectLiteral::Property::COMPUTED: | 2107 case ObjectLiteral::Property::COMPUTED: |
| 2107 __ CallRuntime(Runtime::kDefineClassMethod); | 2108 __ Mov(x0, Smi::FromInt(DONT_ENUM)); |
| 2109 __ Push(x0); |
| 2110 __ Push(Smi::FromInt(property->NeedsSetFunctionName())); |
| 2111 __ CallRuntime(Runtime::kDefineDataPropertyInLiteral); |
| 2108 break; | 2112 break; |
| 2109 | 2113 |
| 2110 case ObjectLiteral::Property::GETTER: | 2114 case ObjectLiteral::Property::GETTER: |
| 2111 __ Mov(x0, Smi::FromInt(DONT_ENUM)); | 2115 __ Mov(x0, Smi::FromInt(DONT_ENUM)); |
| 2112 __ Push(x0); | 2116 __ Push(x0); |
| 2113 __ CallRuntime(Runtime::kDefineGetterPropertyUnchecked); | 2117 __ CallRuntime(Runtime::kDefineGetterPropertyUnchecked); |
| 2114 break; | 2118 break; |
| 2115 | 2119 |
| 2116 case ObjectLiteral::Property::SETTER: | 2120 case ObjectLiteral::Property::SETTER: |
| 2117 __ Mov(x0, Smi::FromInt(DONT_ENUM)); | 2121 __ Mov(x0, Smi::FromInt(DONT_ENUM)); |
| (...skipping 2711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4829 } | 4833 } |
| 4830 | 4834 |
| 4831 return INTERRUPT; | 4835 return INTERRUPT; |
| 4832 } | 4836 } |
| 4833 | 4837 |
| 4834 | 4838 |
| 4835 } // namespace internal | 4839 } // namespace internal |
| 4836 } // namespace v8 | 4840 } // namespace v8 |
| 4837 | 4841 |
| 4838 #endif // V8_TARGET_ARCH_ARM64 | 4842 #endif // V8_TARGET_ARCH_ARM64 |
| OLD | NEW |