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

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

Issue 795573005: ES6 computed property names (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: moar cleanup Created 6 years 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 | « no previous file | src/arm64/full-codegen-arm64.cc » ('j') | src/ia32/full-codegen-ia32.cc » ('J')
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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM 7 #if V8_TARGET_ARCH_ARM
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 2470 matching lines...) Expand 10 before | Expand all | Expand 10 after
2481 Literal* key = property->key()->AsLiteral(); 2481 Literal* key = property->key()->AsLiteral();
2482 Expression* value = property->value(); 2482 Expression* value = property->value();
2483 DCHECK(key != NULL); 2483 DCHECK(key != NULL);
2484 2484
2485 if (property->is_static()) { 2485 if (property->is_static()) {
2486 __ ldr(scratch, MemOperand(sp, kPointerSize)); // constructor 2486 __ ldr(scratch, MemOperand(sp, kPointerSize)); // constructor
2487 } else { 2487 } else {
2488 __ ldr(scratch, MemOperand(sp, 0)); // prototype 2488 __ ldr(scratch, MemOperand(sp, 0)); // prototype
2489 } 2489 }
2490 __ push(scratch); 2490 __ push(scratch);
2491 VisitForStackValue(key); 2491 EmitPropertyKey(property);
2492 VisitForStackValue(value); 2492 VisitForStackValue(value);
2493 EmitSetHomeObjectIfNeeded(value, 2); 2493 EmitSetHomeObjectIfNeeded(value, 2);
2494 2494
2495 switch (property->kind()) { 2495 switch (property->kind()) {
2496 case ObjectLiteral::Property::CONSTANT: 2496 case ObjectLiteral::Property::CONSTANT:
2497 case ObjectLiteral::Property::MATERIALIZED_LITERAL: 2497 case ObjectLiteral::Property::MATERIALIZED_LITERAL:
2498 case ObjectLiteral::Property::COMPUTED: 2498 case ObjectLiteral::Property::COMPUTED:
2499 case ObjectLiteral::Property::PROTOTYPE: 2499 case ObjectLiteral::Property::PROTOTYPE:
2500 __ CallRuntime(Runtime::kDefineClassMethod, 3); 2500 __ CallRuntime(Runtime::kDefineClassMethod, 3);
2501 break; 2501 break;
2502 2502
2503 case ObjectLiteral::Property::GETTER: 2503 case ObjectLiteral::Property::GETTER:
2504 __ CallRuntime(Runtime::kDefineClassGetter, 3); 2504 __ CallRuntime(Runtime::kDefineGetterPropertyUnchecked, 3);
2505 break; 2505 break;
2506 2506
2507 case ObjectLiteral::Property::SETTER: 2507 case ObjectLiteral::Property::SETTER:
2508 __ CallRuntime(Runtime::kDefineClassSetter, 3); 2508 __ CallRuntime(Runtime::kDefineSetterPropertyUnchecked, 3);
2509 break; 2509 break;
2510 2510
2511 default: 2511 default:
2512 UNREACHABLE(); 2512 UNREACHABLE();
2513 } 2513 }
2514 } 2514 }
2515 2515
2516 // prototype 2516 // prototype
2517 __ CallRuntime(Runtime::kToFastProperties, 1); 2517 __ CallRuntime(Runtime::kToFastProperties, 1);
2518 2518
(...skipping 2780 matching lines...) Expand 10 before | Expand all | Expand 10 after
5299 5299
5300 DCHECK(interrupt_address == 5300 DCHECK(interrupt_address ==
5301 isolate->builtins()->OsrAfterStackCheck()->entry()); 5301 isolate->builtins()->OsrAfterStackCheck()->entry());
5302 return OSR_AFTER_STACK_CHECK; 5302 return OSR_AFTER_STACK_CHECK;
5303 } 5303 }
5304 5304
5305 5305
5306 } } // namespace v8::internal 5306 } } // namespace v8::internal
5307 5307
5308 #endif // V8_TARGET_ARCH_ARM 5308 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm64/full-codegen-arm64.cc » ('j') | src/ia32/full-codegen-ia32.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698