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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_X87 | 7 #if V8_TARGET_ARCH_X87 |
8 | 8 |
9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 1649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1660 __ Drop(3); | 1660 __ Drop(3); |
1661 } | 1661 } |
1662 break; | 1662 break; |
1663 case ObjectLiteral::Property::PROTOTYPE: | 1663 case ObjectLiteral::Property::PROTOTYPE: |
1664 __ push(Operand(esp, 0)); // Duplicate receiver. | 1664 __ push(Operand(esp, 0)); // Duplicate receiver. |
1665 VisitForStackValue(value); | 1665 VisitForStackValue(value); |
1666 DCHECK(property->emit_store()); | 1666 DCHECK(property->emit_store()); |
1667 __ CallRuntime(Runtime::kInternalSetPrototype, 2); | 1667 __ CallRuntime(Runtime::kInternalSetPrototype, 2); |
1668 break; | 1668 break; |
1669 case ObjectLiteral::Property::GETTER: | 1669 case ObjectLiteral::Property::GETTER: |
1670 accessor_table.lookup(key)->second->getter = value; | 1670 if (property->emit_store()) { |
| 1671 accessor_table.lookup(key)->second->getter = value; |
| 1672 } |
1671 break; | 1673 break; |
1672 case ObjectLiteral::Property::SETTER: | 1674 case ObjectLiteral::Property::SETTER: |
1673 accessor_table.lookup(key)->second->setter = value; | 1675 if (property->emit_store()) { |
| 1676 accessor_table.lookup(key)->second->setter = value; |
| 1677 } |
1674 break; | 1678 break; |
1675 } | 1679 } |
1676 } | 1680 } |
1677 | 1681 |
1678 // Emit code to define accessors, using only a single call to the runtime for | 1682 // Emit code to define accessors, using only a single call to the runtime for |
1679 // each pair of corresponding getters and setters. | 1683 // each pair of corresponding getters and setters. |
1680 for (AccessorTable::Iterator it = accessor_table.begin(); | 1684 for (AccessorTable::Iterator it = accessor_table.begin(); |
1681 it != accessor_table.end(); | 1685 it != accessor_table.end(); |
1682 ++it) { | 1686 ++it) { |
1683 __ push(Operand(esp, 0)); // Duplicate receiver. | 1687 __ push(Operand(esp, 0)); // Duplicate receiver. |
(...skipping 3535 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5219 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 5223 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
5220 Assembler::target_address_at(call_target_address, | 5224 Assembler::target_address_at(call_target_address, |
5221 unoptimized_code)); | 5225 unoptimized_code)); |
5222 return OSR_AFTER_STACK_CHECK; | 5226 return OSR_AFTER_STACK_CHECK; |
5223 } | 5227 } |
5224 | 5228 |
5225 | 5229 |
5226 } } // namespace v8::internal | 5230 } } // namespace v8::internal |
5227 | 5231 |
5228 #endif // V8_TARGET_ARCH_X87 | 5232 #endif // V8_TARGET_ARCH_X87 |
OLD | NEW |