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

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

Issue 873823003: Move object literal checking into checker classes (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix assert 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
« no previous file with comments | « src/parser.cc ('k') | src/preparser.h » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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_PPC 7 #if V8_TARGET_ARCH_PPC
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 1695 matching lines...) Expand 10 before | Expand all | Expand 10 after
1706 __ CallRuntime(Runtime::kSetProperty, 4); 1706 __ CallRuntime(Runtime::kSetProperty, 4);
1707 } else { 1707 } else {
1708 __ Drop(3); 1708 __ Drop(3);
1709 } 1709 }
1710 break; 1710 break;
1711 case ObjectLiteral::Property::PROTOTYPE: 1711 case ObjectLiteral::Property::PROTOTYPE:
1712 // Duplicate receiver on stack. 1712 // Duplicate receiver on stack.
1713 __ LoadP(r3, MemOperand(sp)); 1713 __ LoadP(r3, MemOperand(sp));
1714 __ push(r3); 1714 __ push(r3);
1715 VisitForStackValue(value); 1715 VisitForStackValue(value);
1716 if (property->emit_store()) { 1716 DCHECK(property->emit_store());
1717 __ CallRuntime(Runtime::kInternalSetPrototype, 2); 1717 __ CallRuntime(Runtime::kInternalSetPrototype, 2);
1718 } else {
1719 __ Drop(2);
1720 }
1721 break; 1718 break;
1722 case ObjectLiteral::Property::GETTER: 1719 case ObjectLiteral::Property::GETTER:
1723 accessor_table.lookup(key)->second->getter = value; 1720 accessor_table.lookup(key)->second->getter = value;
1724 break; 1721 break;
1725 case ObjectLiteral::Property::SETTER: 1722 case ObjectLiteral::Property::SETTER:
1726 accessor_table.lookup(key)->second->setter = value; 1723 accessor_table.lookup(key)->second->setter = value;
1727 break; 1724 break;
1728 } 1725 }
1729 } 1726 }
1730 1727
(...skipping 791 matching lines...) Expand 10 before | Expand all | Expand 10 after
2522 } else { 2519 } else {
2523 __ LoadP(scratch, MemOperand(sp, 0)); // prototype 2520 __ LoadP(scratch, MemOperand(sp, 0)); // prototype
2524 } 2521 }
2525 __ push(scratch); 2522 __ push(scratch);
2526 VisitForStackValue(key); 2523 VisitForStackValue(key);
2527 VisitForStackValue(value); 2524 VisitForStackValue(value);
2528 2525
2529 switch (property->kind()) { 2526 switch (property->kind()) {
2530 case ObjectLiteral::Property::CONSTANT: 2527 case ObjectLiteral::Property::CONSTANT:
2531 case ObjectLiteral::Property::MATERIALIZED_LITERAL: 2528 case ObjectLiteral::Property::MATERIALIZED_LITERAL:
2529 case ObjectLiteral::Property::PROTOTYPE:
2530 UNREACHABLE();
2532 case ObjectLiteral::Property::COMPUTED: 2531 case ObjectLiteral::Property::COMPUTED:
2533 case ObjectLiteral::Property::PROTOTYPE:
2534 __ CallRuntime(Runtime::kDefineClassMethod, 3); 2532 __ CallRuntime(Runtime::kDefineClassMethod, 3);
2535 break; 2533 break;
2536 2534
2537 case ObjectLiteral::Property::GETTER: 2535 case ObjectLiteral::Property::GETTER:
2538 __ CallRuntime(Runtime::kDefineClassGetter, 3); 2536 __ CallRuntime(Runtime::kDefineClassGetter, 3);
2539 break; 2537 break;
2540 2538
2541 case ObjectLiteral::Property::SETTER: 2539 case ObjectLiteral::Property::SETTER:
2542 __ CallRuntime(Runtime::kDefineClassSetter, 3); 2540 __ CallRuntime(Runtime::kDefineClassSetter, 3);
2543 break; 2541 break;
(...skipping 2739 matching lines...) Expand 10 before | Expand all | Expand 10 after
5283 return ON_STACK_REPLACEMENT; 5281 return ON_STACK_REPLACEMENT;
5284 } 5282 }
5285 5283
5286 DCHECK(interrupt_address == 5284 DCHECK(interrupt_address ==
5287 isolate->builtins()->OsrAfterStackCheck()->entry()); 5285 isolate->builtins()->OsrAfterStackCheck()->entry());
5288 return OSR_AFTER_STACK_CHECK; 5286 return OSR_AFTER_STACK_CHECK;
5289 } 5287 }
5290 } 5288 }
5291 } // namespace v8::internal 5289 } // namespace v8::internal
5292 #endif // V8_TARGET_ARCH_PPC 5290 #endif // V8_TARGET_ARCH_PPC
OLDNEW
« no previous file with comments | « src/parser.cc ('k') | src/preparser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698