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_IA32 | 7 #if V8_TARGET_ARCH_IA32 |
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 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
231 } else if (FLAG_debug_code) { | 231 } else if (FLAG_debug_code) { |
232 Label done; | 232 Label done; |
233 __ JumpIfInNewSpace(esi, eax, &done, Label::kNear); | 233 __ JumpIfInNewSpace(esi, eax, &done, Label::kNear); |
234 __ Abort(kExpectedNewSpaceObject); | 234 __ Abort(kExpectedNewSpaceObject); |
235 __ bind(&done); | 235 __ bind(&done); |
236 } | 236 } |
237 } | 237 } |
238 } | 238 } |
239 } | 239 } |
240 | 240 |
| 241 Variable* home_object_var = scope()->home_object_var(); |
| 242 if (home_object_var != nullptr) { |
| 243 __ push(edi); |
| 244 } |
| 245 |
241 ArgumentsAccessStub::HasNewTarget has_new_target = | 246 ArgumentsAccessStub::HasNewTarget has_new_target = |
242 IsSubclassConstructor(info->function()->kind()) | 247 IsSubclassConstructor(info->function()->kind()) |
243 ? ArgumentsAccessStub::HAS_NEW_TARGET | 248 ? ArgumentsAccessStub::HAS_NEW_TARGET |
244 : ArgumentsAccessStub::NO_NEW_TARGET; | 249 : ArgumentsAccessStub::NO_NEW_TARGET; |
245 | 250 |
246 // Possibly allocate RestParameters | 251 // Possibly allocate RestParameters |
247 int rest_index; | 252 int rest_index; |
248 Variable* rest_param = scope()->rest_parameter(&rest_index); | 253 Variable* rest_param = scope()->rest_parameter(&rest_index); |
249 if (rest_param) { | 254 if (rest_param) { |
250 Comment cmnt(masm_, "[ Allocate rest parameter array"); | 255 Comment cmnt(masm_, "[ Allocate rest parameter array"); |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
296 } else { | 301 } else { |
297 type = ArgumentsAccessStub::NEW_SLOPPY_FAST; | 302 type = ArgumentsAccessStub::NEW_SLOPPY_FAST; |
298 } | 303 } |
299 | 304 |
300 ArgumentsAccessStub stub(isolate(), type, has_new_target); | 305 ArgumentsAccessStub stub(isolate(), type, has_new_target); |
301 __ CallStub(&stub); | 306 __ CallStub(&stub); |
302 | 307 |
303 SetVar(arguments, eax, ebx, edx); | 308 SetVar(arguments, eax, ebx, edx); |
304 } | 309 } |
305 | 310 |
| 311 // Possibly set up a local binding to the [[HomeObject]]. |
| 312 if (home_object_var != nullptr) { |
| 313 Comment cmnt(masm_, "[ Home object"); |
| 314 __ pop(LoadDescriptor::ReceiverRegister()); |
| 315 Handle<Symbol> home_object_symbol(isolate()->heap()->home_object_symbol()); |
| 316 __ mov(LoadDescriptor::NameRegister(), Immediate(home_object_symbol)); |
| 317 __ mov(LoadDescriptor::SlotRegister(), |
| 318 Immediate(SmiFromSlot(function()->HomeObjectFeedbackSlot()))); |
| 319 CallLoadIC(NOT_CONTEXTUAL); |
| 320 |
| 321 SetVar(home_object_var, eax, ebx, edx); |
| 322 } |
| 323 |
306 if (FLAG_trace) { | 324 if (FLAG_trace) { |
307 __ CallRuntime(Runtime::kTraceEnter, 0); | 325 __ CallRuntime(Runtime::kTraceEnter, 0); |
308 } | 326 } |
309 | 327 |
310 // Visit the declarations and body unless there is an illegal | 328 // Visit the declarations and body unless there is an illegal |
311 // redeclaration. | 329 // redeclaration. |
312 if (scope()->HasIllegalRedeclaration()) { | 330 if (scope()->HasIllegalRedeclaration()) { |
313 Comment cmnt(masm_, "[ Declarations"); | 331 Comment cmnt(masm_, "[ Declarations"); |
314 scope()->VisitIllegalRedeclaration(this); | 332 scope()->VisitIllegalRedeclaration(this); |
315 | 333 |
(...skipping 928 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1244 context()->Plug(eax); | 1262 context()->Plug(eax); |
1245 } | 1263 } |
1246 | 1264 |
1247 | 1265 |
1248 void FullCodeGenerator::VisitVariableProxy(VariableProxy* expr) { | 1266 void FullCodeGenerator::VisitVariableProxy(VariableProxy* expr) { |
1249 Comment cmnt(masm_, "[ VariableProxy"); | 1267 Comment cmnt(masm_, "[ VariableProxy"); |
1250 EmitVariableLoad(expr); | 1268 EmitVariableLoad(expr); |
1251 } | 1269 } |
1252 | 1270 |
1253 | 1271 |
1254 void FullCodeGenerator::EmitLoadHomeObject(SuperReference* expr) { | |
1255 Comment cnmt(masm_, "[ SuperReference "); | |
1256 | |
1257 __ mov(LoadDescriptor::ReceiverRegister(), | |
1258 Operand(ebp, JavaScriptFrameConstants::kFunctionOffset)); | |
1259 | |
1260 Handle<Symbol> home_object_symbol(isolate()->heap()->home_object_symbol()); | |
1261 __ mov(LoadDescriptor::NameRegister(), home_object_symbol); | |
1262 | |
1263 __ mov(LoadDescriptor::SlotRegister(), | |
1264 Immediate(SmiFromSlot(expr->HomeObjectFeedbackSlot()))); | |
1265 CallLoadIC(NOT_CONTEXTUAL); | |
1266 | |
1267 __ cmp(eax, isolate()->factory()->undefined_value()); | |
1268 Label done; | |
1269 __ j(not_equal, &done); | |
1270 __ CallRuntime(Runtime::kThrowNonMethodError, 0); | |
1271 __ bind(&done); | |
1272 } | |
1273 | |
1274 | |
1275 void FullCodeGenerator::EmitSetHomeObjectIfNeeded(Expression* initializer, | 1272 void FullCodeGenerator::EmitSetHomeObjectIfNeeded(Expression* initializer, |
1276 int offset) { | 1273 int offset) { |
1277 if (NeedsHomeObject(initializer)) { | 1274 if (NeedsHomeObject(initializer)) { |
1278 __ mov(StoreDescriptor::ReceiverRegister(), Operand(esp, 0)); | 1275 __ mov(StoreDescriptor::ReceiverRegister(), Operand(esp, 0)); |
1279 __ mov(StoreDescriptor::NameRegister(), | 1276 __ mov(StoreDescriptor::NameRegister(), |
1280 Immediate(isolate()->factory()->home_object_symbol())); | 1277 Immediate(isolate()->factory()->home_object_symbol())); |
1281 __ mov(StoreDescriptor::ValueRegister(), | 1278 __ mov(StoreDescriptor::ValueRegister(), |
1282 Operand(esp, offset * kPointerSize)); | 1279 Operand(esp, offset * kPointerSize)); |
1283 CallStoreIC(); | 1280 CallStoreIC(); |
1284 } | 1281 } |
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1868 Property* property = expr->target()->AsProperty(); | 1865 Property* property = expr->target()->AsProperty(); |
1869 LhsKind assign_type = GetAssignType(property); | 1866 LhsKind assign_type = GetAssignType(property); |
1870 | 1867 |
1871 // Evaluate LHS expression. | 1868 // Evaluate LHS expression. |
1872 switch (assign_type) { | 1869 switch (assign_type) { |
1873 case VARIABLE: | 1870 case VARIABLE: |
1874 // Nothing to do here. | 1871 // Nothing to do here. |
1875 break; | 1872 break; |
1876 case NAMED_SUPER_PROPERTY: | 1873 case NAMED_SUPER_PROPERTY: |
1877 VisitForStackValue(property->obj()->AsSuperReference()->this_var()); | 1874 VisitForStackValue(property->obj()->AsSuperReference()->this_var()); |
1878 EmitLoadHomeObject(property->obj()->AsSuperReference()); | 1875 VisitForAccumulatorValue( |
| 1876 property->obj()->AsSuperReference()->home_object_var()); |
1879 __ push(result_register()); | 1877 __ push(result_register()); |
1880 if (expr->is_compound()) { | 1878 if (expr->is_compound()) { |
1881 __ push(MemOperand(esp, kPointerSize)); | 1879 __ push(MemOperand(esp, kPointerSize)); |
1882 __ push(result_register()); | 1880 __ push(result_register()); |
1883 } | 1881 } |
1884 break; | 1882 break; |
1885 case NAMED_PROPERTY: | 1883 case NAMED_PROPERTY: |
1886 if (expr->is_compound()) { | 1884 if (expr->is_compound()) { |
1887 // We need the receiver both on the stack and in the register. | 1885 // We need the receiver both on the stack and in the register. |
1888 VisitForStackValue(property->obj()); | 1886 VisitForStackValue(property->obj()); |
1889 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); | 1887 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); |
1890 } else { | 1888 } else { |
1891 VisitForStackValue(property->obj()); | 1889 VisitForStackValue(property->obj()); |
1892 } | 1890 } |
1893 break; | 1891 break; |
1894 case KEYED_SUPER_PROPERTY: | 1892 case KEYED_SUPER_PROPERTY: |
1895 VisitForStackValue(property->obj()->AsSuperReference()->this_var()); | 1893 VisitForStackValue(property->obj()->AsSuperReference()->this_var()); |
1896 EmitLoadHomeObject(property->obj()->AsSuperReference()); | 1894 VisitForStackValue( |
1897 __ Push(result_register()); | 1895 property->obj()->AsSuperReference()->home_object_var()); |
1898 VisitForAccumulatorValue(property->key()); | 1896 VisitForAccumulatorValue(property->key()); |
1899 __ Push(result_register()); | 1897 __ Push(result_register()); |
1900 if (expr->is_compound()) { | 1898 if (expr->is_compound()) { |
1901 __ push(MemOperand(esp, 2 * kPointerSize)); | 1899 __ push(MemOperand(esp, 2 * kPointerSize)); |
1902 __ push(MemOperand(esp, 2 * kPointerSize)); | 1900 __ push(MemOperand(esp, 2 * kPointerSize)); |
1903 __ push(result_register()); | 1901 __ push(result_register()); |
1904 } | 1902 } |
1905 break; | 1903 break; |
1906 case KEYED_PROPERTY: { | 1904 case KEYED_PROPERTY: { |
1907 if (expr->is_compound()) { | 1905 if (expr->is_compound()) { |
(...skipping 602 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2510 __ Move(StoreDescriptor::ReceiverRegister(), eax); | 2508 __ Move(StoreDescriptor::ReceiverRegister(), eax); |
2511 __ pop(StoreDescriptor::ValueRegister()); // Restore value. | 2509 __ pop(StoreDescriptor::ValueRegister()); // Restore value. |
2512 __ mov(StoreDescriptor::NameRegister(), | 2510 __ mov(StoreDescriptor::NameRegister(), |
2513 prop->key()->AsLiteral()->value()); | 2511 prop->key()->AsLiteral()->value()); |
2514 CallStoreIC(); | 2512 CallStoreIC(); |
2515 break; | 2513 break; |
2516 } | 2514 } |
2517 case NAMED_SUPER_PROPERTY: { | 2515 case NAMED_SUPER_PROPERTY: { |
2518 __ push(eax); | 2516 __ push(eax); |
2519 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); | 2517 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); |
2520 EmitLoadHomeObject(prop->obj()->AsSuperReference()); | 2518 VisitForAccumulatorValue( |
| 2519 prop->obj()->AsSuperReference()->home_object_var()); |
2521 // stack: value, this; eax: home_object | 2520 // stack: value, this; eax: home_object |
2522 Register scratch = ecx; | 2521 Register scratch = ecx; |
2523 Register scratch2 = edx; | 2522 Register scratch2 = edx; |
2524 __ mov(scratch, result_register()); // home_object | 2523 __ mov(scratch, result_register()); // home_object |
2525 __ mov(eax, MemOperand(esp, kPointerSize)); // value | 2524 __ mov(eax, MemOperand(esp, kPointerSize)); // value |
2526 __ mov(scratch2, MemOperand(esp, 0)); // this | 2525 __ mov(scratch2, MemOperand(esp, 0)); // this |
2527 __ mov(MemOperand(esp, kPointerSize), scratch2); // this | 2526 __ mov(MemOperand(esp, kPointerSize), scratch2); // this |
2528 __ mov(MemOperand(esp, 0), scratch); // home_object | 2527 __ mov(MemOperand(esp, 0), scratch); // home_object |
2529 // stack: this, home_object. eax: value | 2528 // stack: this, home_object. eax: value |
2530 EmitNamedSuperPropertyStore(prop); | 2529 EmitNamedSuperPropertyStore(prop); |
2531 break; | 2530 break; |
2532 } | 2531 } |
2533 case KEYED_SUPER_PROPERTY: { | 2532 case KEYED_SUPER_PROPERTY: { |
2534 __ push(eax); | 2533 __ push(eax); |
2535 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); | 2534 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); |
2536 EmitLoadHomeObject(prop->obj()->AsSuperReference()); | 2535 VisitForStackValue(prop->obj()->AsSuperReference()->home_object_var()); |
2537 __ push(result_register()); | |
2538 VisitForAccumulatorValue(prop->key()); | 2536 VisitForAccumulatorValue(prop->key()); |
2539 Register scratch = ecx; | 2537 Register scratch = ecx; |
2540 Register scratch2 = edx; | 2538 Register scratch2 = edx; |
2541 __ mov(scratch2, MemOperand(esp, 2 * kPointerSize)); // value | 2539 __ mov(scratch2, MemOperand(esp, 2 * kPointerSize)); // value |
2542 // stack: value, this, home_object; eax: key, edx: value | 2540 // stack: value, this, home_object; eax: key, edx: value |
2543 __ mov(scratch, MemOperand(esp, kPointerSize)); // this | 2541 __ mov(scratch, MemOperand(esp, kPointerSize)); // this |
2544 __ mov(MemOperand(esp, 2 * kPointerSize), scratch); | 2542 __ mov(MemOperand(esp, 2 * kPointerSize), scratch); |
2545 __ mov(scratch, MemOperand(esp, 0)); // home_object | 2543 __ mov(scratch, MemOperand(esp, 0)); // home_object |
2546 __ mov(MemOperand(esp, kPointerSize), scratch); | 2544 __ mov(MemOperand(esp, kPointerSize), scratch); |
2547 __ mov(MemOperand(esp, 0), eax); | 2545 __ mov(MemOperand(esp, 0), eax); |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2738 Comment cmnt(masm_, "[ Property"); | 2736 Comment cmnt(masm_, "[ Property"); |
2739 Expression* key = expr->key(); | 2737 Expression* key = expr->key(); |
2740 | 2738 |
2741 if (key->IsPropertyName()) { | 2739 if (key->IsPropertyName()) { |
2742 if (!expr->IsSuperAccess()) { | 2740 if (!expr->IsSuperAccess()) { |
2743 VisitForAccumulatorValue(expr->obj()); | 2741 VisitForAccumulatorValue(expr->obj()); |
2744 __ Move(LoadDescriptor::ReceiverRegister(), result_register()); | 2742 __ Move(LoadDescriptor::ReceiverRegister(), result_register()); |
2745 EmitNamedPropertyLoad(expr); | 2743 EmitNamedPropertyLoad(expr); |
2746 } else { | 2744 } else { |
2747 VisitForStackValue(expr->obj()->AsSuperReference()->this_var()); | 2745 VisitForStackValue(expr->obj()->AsSuperReference()->this_var()); |
2748 EmitLoadHomeObject(expr->obj()->AsSuperReference()); | 2746 VisitForStackValue(expr->obj()->AsSuperReference()->home_object_var()); |
2749 __ push(result_register()); | |
2750 EmitNamedSuperPropertyLoad(expr); | 2747 EmitNamedSuperPropertyLoad(expr); |
2751 } | 2748 } |
2752 } else { | 2749 } else { |
2753 if (!expr->IsSuperAccess()) { | 2750 if (!expr->IsSuperAccess()) { |
2754 VisitForStackValue(expr->obj()); | 2751 VisitForStackValue(expr->obj()); |
2755 VisitForAccumulatorValue(expr->key()); | 2752 VisitForAccumulatorValue(expr->key()); |
2756 __ pop(LoadDescriptor::ReceiverRegister()); // Object. | 2753 __ pop(LoadDescriptor::ReceiverRegister()); // Object. |
2757 __ Move(LoadDescriptor::NameRegister(), result_register()); // Key. | 2754 __ Move(LoadDescriptor::NameRegister(), result_register()); // Key. |
2758 EmitKeyedPropertyLoad(expr); | 2755 EmitKeyedPropertyLoad(expr); |
2759 } else { | 2756 } else { |
2760 VisitForStackValue(expr->obj()->AsSuperReference()->this_var()); | 2757 VisitForStackValue(expr->obj()->AsSuperReference()->this_var()); |
2761 EmitLoadHomeObject(expr->obj()->AsSuperReference()); | 2758 VisitForStackValue(expr->obj()->AsSuperReference()->home_object_var()); |
2762 __ push(result_register()); | |
2763 VisitForStackValue(expr->key()); | 2759 VisitForStackValue(expr->key()); |
2764 EmitKeyedSuperPropertyLoad(expr); | 2760 EmitKeyedSuperPropertyLoad(expr); |
2765 } | 2761 } |
2766 } | 2762 } |
2767 PrepareForBailoutForId(expr->LoadId(), TOS_REG); | 2763 PrepareForBailoutForId(expr->LoadId(), TOS_REG); |
2768 context()->Plug(eax); | 2764 context()->Plug(eax); |
2769 } | 2765 } |
2770 | 2766 |
2771 | 2767 |
2772 void FullCodeGenerator::CallIC(Handle<Code> code, | 2768 void FullCodeGenerator::CallIC(Handle<Code> code, |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2811 Expression* callee = expr->expression(); | 2807 Expression* callee = expr->expression(); |
2812 DCHECK(callee->IsProperty()); | 2808 DCHECK(callee->IsProperty()); |
2813 Property* prop = callee->AsProperty(); | 2809 Property* prop = callee->AsProperty(); |
2814 DCHECK(prop->IsSuperAccess()); | 2810 DCHECK(prop->IsSuperAccess()); |
2815 | 2811 |
2816 SetSourcePosition(prop->position()); | 2812 SetSourcePosition(prop->position()); |
2817 Literal* key = prop->key()->AsLiteral(); | 2813 Literal* key = prop->key()->AsLiteral(); |
2818 DCHECK(!key->value()->IsSmi()); | 2814 DCHECK(!key->value()->IsSmi()); |
2819 // Load the function from the receiver. | 2815 // Load the function from the receiver. |
2820 SuperReference* super_ref = callee->AsProperty()->obj()->AsSuperReference(); | 2816 SuperReference* super_ref = callee->AsProperty()->obj()->AsSuperReference(); |
2821 EmitLoadHomeObject(super_ref); | 2817 VisitForStackValue(super_ref->home_object_var()); |
2822 __ push(eax); | |
2823 VisitForAccumulatorValue(super_ref->this_var()); | 2818 VisitForAccumulatorValue(super_ref->this_var()); |
2824 __ push(eax); | 2819 __ push(eax); |
2825 __ push(eax); | 2820 __ push(eax); |
2826 __ push(Operand(esp, kPointerSize * 2)); | 2821 __ push(Operand(esp, kPointerSize * 2)); |
2827 __ push(Immediate(key->value())); | 2822 __ push(Immediate(key->value())); |
2828 // Stack here: | 2823 // Stack here: |
2829 // - home_object | 2824 // - home_object |
2830 // - this (receiver) | 2825 // - this (receiver) |
2831 // - this (receiver) <-- LoadFromSuper will pop here and below. | 2826 // - this (receiver) <-- LoadFromSuper will pop here and below. |
2832 // - home_object | 2827 // - home_object |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2868 | 2863 |
2869 void FullCodeGenerator::EmitKeyedSuperCallWithLoadIC(Call* expr) { | 2864 void FullCodeGenerator::EmitKeyedSuperCallWithLoadIC(Call* expr) { |
2870 Expression* callee = expr->expression(); | 2865 Expression* callee = expr->expression(); |
2871 DCHECK(callee->IsProperty()); | 2866 DCHECK(callee->IsProperty()); |
2872 Property* prop = callee->AsProperty(); | 2867 Property* prop = callee->AsProperty(); |
2873 DCHECK(prop->IsSuperAccess()); | 2868 DCHECK(prop->IsSuperAccess()); |
2874 | 2869 |
2875 SetSourcePosition(prop->position()); | 2870 SetSourcePosition(prop->position()); |
2876 // Load the function from the receiver. | 2871 // Load the function from the receiver. |
2877 SuperReference* super_ref = callee->AsProperty()->obj()->AsSuperReference(); | 2872 SuperReference* super_ref = callee->AsProperty()->obj()->AsSuperReference(); |
2878 EmitLoadHomeObject(super_ref); | 2873 VisitForStackValue(super_ref->home_object_var()); |
2879 __ push(eax); | |
2880 VisitForAccumulatorValue(super_ref->this_var()); | 2874 VisitForAccumulatorValue(super_ref->this_var()); |
2881 __ push(eax); | 2875 __ push(eax); |
2882 __ push(eax); | 2876 __ push(eax); |
2883 __ push(Operand(esp, kPointerSize * 2)); | 2877 __ push(Operand(esp, kPointerSize * 2)); |
2884 VisitForStackValue(prop->key()); | 2878 VisitForStackValue(prop->key()); |
2885 // Stack here: | 2879 // Stack here: |
2886 // - home_object | 2880 // - home_object |
2887 // - this (receiver) | 2881 // - this (receiver) |
2888 // - this (receiver) <-- LoadKeyedFromSuper will pop here and below. | 2882 // - this (receiver) <-- LoadKeyedFromSuper will pop here and below. |
2889 // - home_object | 2883 // - home_object |
(...skipping 1851 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4741 case NAMED_PROPERTY: { | 4735 case NAMED_PROPERTY: { |
4742 // Put the object both on the stack and in the register. | 4736 // Put the object both on the stack and in the register. |
4743 VisitForStackValue(prop->obj()); | 4737 VisitForStackValue(prop->obj()); |
4744 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); | 4738 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); |
4745 EmitNamedPropertyLoad(prop); | 4739 EmitNamedPropertyLoad(prop); |
4746 break; | 4740 break; |
4747 } | 4741 } |
4748 | 4742 |
4749 case NAMED_SUPER_PROPERTY: { | 4743 case NAMED_SUPER_PROPERTY: { |
4750 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); | 4744 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); |
4751 EmitLoadHomeObject(prop->obj()->AsSuperReference()); | 4745 VisitForAccumulatorValue( |
| 4746 prop->obj()->AsSuperReference()->home_object_var()); |
4752 __ push(result_register()); | 4747 __ push(result_register()); |
4753 __ push(MemOperand(esp, kPointerSize)); | 4748 __ push(MemOperand(esp, kPointerSize)); |
4754 __ push(result_register()); | 4749 __ push(result_register()); |
4755 EmitNamedSuperPropertyLoad(prop); | 4750 EmitNamedSuperPropertyLoad(prop); |
4756 break; | 4751 break; |
4757 } | 4752 } |
4758 | 4753 |
4759 case KEYED_SUPER_PROPERTY: { | 4754 case KEYED_SUPER_PROPERTY: { |
4760 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); | 4755 VisitForStackValue(prop->obj()->AsSuperReference()->this_var()); |
4761 EmitLoadHomeObject(prop->obj()->AsSuperReference()); | 4756 VisitForStackValue(prop->obj()->AsSuperReference()->home_object_var()); |
4762 __ push(result_register()); | |
4763 VisitForAccumulatorValue(prop->key()); | 4757 VisitForAccumulatorValue(prop->key()); |
4764 __ push(result_register()); | 4758 __ push(result_register()); |
4765 __ push(MemOperand(esp, 2 * kPointerSize)); | 4759 __ push(MemOperand(esp, 2 * kPointerSize)); |
4766 __ push(MemOperand(esp, 2 * kPointerSize)); | 4760 __ push(MemOperand(esp, 2 * kPointerSize)); |
4767 __ push(result_register()); | 4761 __ push(result_register()); |
4768 EmitKeyedSuperPropertyLoad(prop); | 4762 EmitKeyedSuperPropertyLoad(prop); |
4769 break; | 4763 break; |
4770 } | 4764 } |
4771 | 4765 |
4772 case KEYED_PROPERTY: { | 4766 case KEYED_PROPERTY: { |
(...skipping 576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5349 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 5343 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
5350 Assembler::target_address_at(call_target_address, | 5344 Assembler::target_address_at(call_target_address, |
5351 unoptimized_code)); | 5345 unoptimized_code)); |
5352 return OSR_AFTER_STACK_CHECK; | 5346 return OSR_AFTER_STACK_CHECK; |
5353 } | 5347 } |
5354 | 5348 |
5355 | 5349 |
5356 } } // namespace v8::internal | 5350 } } // namespace v8::internal |
5357 | 5351 |
5358 #endif // V8_TARGET_ARCH_IA32 | 5352 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |