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

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

Issue 1555023002: [turbofan] Add deopt point for InternalSetPrototype in VisitObjectLiteral. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 11 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
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | test/mjsunit/compiler/regress-572409.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #if V8_TARGET_ARCH_X87 5 #if V8_TARGET_ARCH_X87
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 1463 matching lines...) Expand 10 before | Expand all | Expand 10 after
1474 __ CallRuntime(Runtime::kSetProperty); 1474 __ CallRuntime(Runtime::kSetProperty);
1475 } else { 1475 } else {
1476 __ Drop(3); 1476 __ Drop(3);
1477 } 1477 }
1478 break; 1478 break;
1479 case ObjectLiteral::Property::PROTOTYPE: 1479 case ObjectLiteral::Property::PROTOTYPE:
1480 __ push(Operand(esp, 0)); // Duplicate receiver. 1480 __ push(Operand(esp, 0)); // Duplicate receiver.
1481 VisitForStackValue(value); 1481 VisitForStackValue(value);
1482 DCHECK(property->emit_store()); 1482 DCHECK(property->emit_store());
1483 __ CallRuntime(Runtime::kInternalSetPrototype); 1483 __ CallRuntime(Runtime::kInternalSetPrototype);
1484 PrepareForBailoutForId(expr->GetIdForPropertySet(property_index),
1485 NO_REGISTERS);
1484 break; 1486 break;
1485 case ObjectLiteral::Property::GETTER: 1487 case ObjectLiteral::Property::GETTER:
1486 if (property->emit_store()) { 1488 if (property->emit_store()) {
1487 accessor_table.lookup(key)->second->getter = property; 1489 accessor_table.lookup(key)->second->getter = property;
1488 } 1490 }
1489 break; 1491 break;
1490 case ObjectLiteral::Property::SETTER: 1492 case ObjectLiteral::Property::SETTER:
1491 if (property->emit_store()) { 1493 if (property->emit_store()) {
1492 accessor_table.lookup(key)->second->setter = property; 1494 accessor_table.lookup(key)->second->setter = property;
1493 } 1495 }
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
1528 result_saved = true; 1530 result_saved = true;
1529 } 1531 }
1530 1532
1531 __ push(Operand(esp, 0)); // Duplicate receiver. 1533 __ push(Operand(esp, 0)); // Duplicate receiver.
1532 1534
1533 if (property->kind() == ObjectLiteral::Property::PROTOTYPE) { 1535 if (property->kind() == ObjectLiteral::Property::PROTOTYPE) {
1534 DCHECK(!property->is_computed_name()); 1536 DCHECK(!property->is_computed_name());
1535 VisitForStackValue(value); 1537 VisitForStackValue(value);
1536 DCHECK(property->emit_store()); 1538 DCHECK(property->emit_store());
1537 __ CallRuntime(Runtime::kInternalSetPrototype); 1539 __ CallRuntime(Runtime::kInternalSetPrototype);
1540 PrepareForBailoutForId(expr->GetIdForPropertySet(property_index),
1541 NO_REGISTERS);
1538 } else { 1542 } else {
1539 EmitPropertyKey(property, expr->GetIdForProperty(property_index)); 1543 EmitPropertyKey(property, expr->GetIdForPropertyName(property_index));
1540 VisitForStackValue(value); 1544 VisitForStackValue(value);
1541 if (NeedsHomeObject(value)) { 1545 if (NeedsHomeObject(value)) {
1542 EmitSetHomeObject(value, 2, property->GetSlot()); 1546 EmitSetHomeObject(value, 2, property->GetSlot());
1543 } 1547 }
1544 1548
1545 switch (property->kind()) { 1549 switch (property->kind()) {
1546 case ObjectLiteral::Property::CONSTANT: 1550 case ObjectLiteral::Property::CONSTANT:
1547 case ObjectLiteral::Property::MATERIALIZED_LITERAL: 1551 case ObjectLiteral::Property::MATERIALIZED_LITERAL:
1548 case ObjectLiteral::Property::COMPUTED: 1552 case ObjectLiteral::Property::COMPUTED:
1549 if (property->emit_store()) { 1553 if (property->emit_store()) {
(...skipping 3221 matching lines...) Expand 10 before | Expand all | Expand 10 after
4771 Assembler::target_address_at(call_target_address, 4775 Assembler::target_address_at(call_target_address,
4772 unoptimized_code)); 4776 unoptimized_code));
4773 return OSR_AFTER_STACK_CHECK; 4777 return OSR_AFTER_STACK_CHECK;
4774 } 4778 }
4775 4779
4776 4780
4777 } // namespace internal 4781 } // namespace internal
4778 } // namespace v8 4782 } // namespace v8
4779 4783
4780 #endif // V8_TARGET_ARCH_X87 4784 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | test/mjsunit/compiler/regress-572409.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698