Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(490)

Side by Side Diff: src/x64/full-codegen-x64.cc

Issue 914773002: Fix issue with super and computed property names (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_X64 7 #if V8_TARGET_ARCH_X64
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 1754 matching lines...) Expand 10 before | Expand all | Expand 10 after
1765 __ Push(Operand(rsp, 0)); // Duplicate receiver. 1765 __ Push(Operand(rsp, 0)); // Duplicate receiver.
1766 1766
1767 if (property->kind() == ObjectLiteral::Property::PROTOTYPE) { 1767 if (property->kind() == ObjectLiteral::Property::PROTOTYPE) {
1768 DCHECK(!property->is_computed_name()); 1768 DCHECK(!property->is_computed_name());
1769 VisitForStackValue(value); 1769 VisitForStackValue(value);
1770 DCHECK(property->emit_store()); 1770 DCHECK(property->emit_store());
1771 __ CallRuntime(Runtime::kInternalSetPrototype, 2); 1771 __ CallRuntime(Runtime::kInternalSetPrototype, 2);
1772 } else { 1772 } else {
1773 EmitPropertyKey(property, expr->GetIdForProperty(property_index)); 1773 EmitPropertyKey(property, expr->GetIdForProperty(property_index));
1774 VisitForStackValue(value); 1774 VisitForStackValue(value);
1775 EmitSetHomeObjectIfNeeded(value, 2);
1775 1776
1776 switch (property->kind()) { 1777 switch (property->kind()) {
1777 case ObjectLiteral::Property::CONSTANT: 1778 case ObjectLiteral::Property::CONSTANT:
1778 case ObjectLiteral::Property::MATERIALIZED_LITERAL: 1779 case ObjectLiteral::Property::MATERIALIZED_LITERAL:
1779 case ObjectLiteral::Property::COMPUTED: 1780 case ObjectLiteral::Property::COMPUTED:
1780 if (property->emit_store()) { 1781 if (property->emit_store()) {
1781 __ Push(Smi::FromInt(NONE)); 1782 __ Push(Smi::FromInt(NONE));
1782 __ CallRuntime(Runtime::kDefineDataPropertyUnchecked, 4); 1783 __ CallRuntime(Runtime::kDefineDataPropertyUnchecked, 4);
1783 } else { 1784 } else {
1784 __ Drop(3); 1785 __ Drop(3);
(...skipping 3530 matching lines...) Expand 10 before | Expand all | Expand 10 after
5315 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 5316 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
5316 Assembler::target_address_at(call_target_address, 5317 Assembler::target_address_at(call_target_address,
5317 unoptimized_code)); 5318 unoptimized_code));
5318 return OSR_AFTER_STACK_CHECK; 5319 return OSR_AFTER_STACK_CHECK;
5319 } 5320 }
5320 5321
5321 5322
5322 } } // namespace v8::internal 5323 } } // namespace v8::internal
5323 5324
5324 #endif // V8_TARGET_ARCH_X64 5325 #endif // V8_TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698