| 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_X87 | 7 #if V8_TARGET_ARCH_X87 |
| 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 1272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1283 Immediate(isolate()->factory()->home_object_symbol())); | 1283 Immediate(isolate()->factory()->home_object_symbol())); |
| 1284 __ mov(StoreDescriptor::ValueRegister(), | 1284 __ mov(StoreDescriptor::ValueRegister(), |
| 1285 Operand(esp, offset * kPointerSize)); | 1285 Operand(esp, offset * kPointerSize)); |
| 1286 if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); | 1286 if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
| 1287 CallStoreIC(); | 1287 CallStoreIC(); |
| 1288 } | 1288 } |
| 1289 } | 1289 } |
| 1290 | 1290 |
| 1291 | 1291 |
| 1292 void FullCodeGenerator::EmitLoadGlobalCheckExtensions(VariableProxy* proxy, | 1292 void FullCodeGenerator::EmitLoadGlobalCheckExtensions(VariableProxy* proxy, |
| 1293 TypeofState typeof_state, | 1293 TypeofMode typeof_mode, |
| 1294 Label* slow) { | 1294 Label* slow) { |
| 1295 Register context = esi; | 1295 Register context = esi; |
| 1296 Register temp = edx; | 1296 Register temp = edx; |
| 1297 | 1297 |
| 1298 Scope* s = scope(); | 1298 Scope* s = scope(); |
| 1299 while (s != NULL) { | 1299 while (s != NULL) { |
| 1300 if (s->num_heap_slots() > 0) { | 1300 if (s->num_heap_slots() > 0) { |
| 1301 if (s->calls_sloppy_eval()) { | 1301 if (s->calls_sloppy_eval()) { |
| 1302 // Check that extension is NULL. | 1302 // Check that extension is NULL. |
| 1303 __ cmp(ContextOperand(context, Context::EXTENSION_INDEX), | 1303 __ cmp(ContextOperand(context, Context::EXTENSION_INDEX), |
| (...skipping 28 matching lines...) Expand all Loading... |
| 1332 __ cmp(ContextOperand(temp, Context::EXTENSION_INDEX), Immediate(0)); | 1332 __ cmp(ContextOperand(temp, Context::EXTENSION_INDEX), Immediate(0)); |
| 1333 __ j(not_equal, slow); | 1333 __ j(not_equal, slow); |
| 1334 // Load next context in chain. | 1334 // Load next context in chain. |
| 1335 __ mov(temp, ContextOperand(temp, Context::PREVIOUS_INDEX)); | 1335 __ mov(temp, ContextOperand(temp, Context::PREVIOUS_INDEX)); |
| 1336 __ jmp(&next); | 1336 __ jmp(&next); |
| 1337 __ bind(&fast); | 1337 __ bind(&fast); |
| 1338 } | 1338 } |
| 1339 | 1339 |
| 1340 // All extension objects were empty and it is safe to use a normal global | 1340 // All extension objects were empty and it is safe to use a normal global |
| 1341 // load machinery. | 1341 // load machinery. |
| 1342 EmitGlobalVariableLoad(proxy, typeof_state); | 1342 EmitGlobalVariableLoad(proxy, typeof_mode); |
| 1343 } | 1343 } |
| 1344 | 1344 |
| 1345 | 1345 |
| 1346 MemOperand FullCodeGenerator::ContextSlotOperandCheckExtensions(Variable* var, | 1346 MemOperand FullCodeGenerator::ContextSlotOperandCheckExtensions(Variable* var, |
| 1347 Label* slow) { | 1347 Label* slow) { |
| 1348 DCHECK(var->IsContextSlot()); | 1348 DCHECK(var->IsContextSlot()); |
| 1349 Register context = esi; | 1349 Register context = esi; |
| 1350 Register temp = ebx; | 1350 Register temp = ebx; |
| 1351 | 1351 |
| 1352 for (Scope* s = scope(); s != var->scope(); s = s->outer_scope()) { | 1352 for (Scope* s = scope(); s != var->scope(); s = s->outer_scope()) { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 1367 __ j(not_equal, slow); | 1367 __ j(not_equal, slow); |
| 1368 | 1368 |
| 1369 // This function is used only for loads, not stores, so it's safe to | 1369 // This function is used only for loads, not stores, so it's safe to |
| 1370 // return an esi-based operand (the write barrier cannot be allowed to | 1370 // return an esi-based operand (the write barrier cannot be allowed to |
| 1371 // destroy the esi register). | 1371 // destroy the esi register). |
| 1372 return ContextOperand(context, var->index()); | 1372 return ContextOperand(context, var->index()); |
| 1373 } | 1373 } |
| 1374 | 1374 |
| 1375 | 1375 |
| 1376 void FullCodeGenerator::EmitDynamicLookupFastCase(VariableProxy* proxy, | 1376 void FullCodeGenerator::EmitDynamicLookupFastCase(VariableProxy* proxy, |
| 1377 TypeofState typeof_state, | 1377 TypeofMode typeof_mode, |
| 1378 Label* slow, | 1378 Label* slow, Label* done) { |
| 1379 Label* done) { | |
| 1380 // Generate fast-case code for variables that might be shadowed by | 1379 // Generate fast-case code for variables that might be shadowed by |
| 1381 // eval-introduced variables. Eval is used a lot without | 1380 // eval-introduced variables. Eval is used a lot without |
| 1382 // introducing variables. In those cases, we do not want to | 1381 // introducing variables. In those cases, we do not want to |
| 1383 // perform a runtime call for all variables in the scope | 1382 // perform a runtime call for all variables in the scope |
| 1384 // containing the eval. | 1383 // containing the eval. |
| 1385 Variable* var = proxy->var(); | 1384 Variable* var = proxy->var(); |
| 1386 if (var->mode() == DYNAMIC_GLOBAL) { | 1385 if (var->mode() == DYNAMIC_GLOBAL) { |
| 1387 EmitLoadGlobalCheckExtensions(proxy, typeof_state, slow); | 1386 EmitLoadGlobalCheckExtensions(proxy, typeof_mode, slow); |
| 1388 __ jmp(done); | 1387 __ jmp(done); |
| 1389 } else if (var->mode() == DYNAMIC_LOCAL) { | 1388 } else if (var->mode() == DYNAMIC_LOCAL) { |
| 1390 Variable* local = var->local_if_not_shadowed(); | 1389 Variable* local = var->local_if_not_shadowed(); |
| 1391 __ mov(eax, ContextSlotOperandCheckExtensions(local, slow)); | 1390 __ mov(eax, ContextSlotOperandCheckExtensions(local, slow)); |
| 1392 if (local->mode() == LET || local->mode() == CONST || | 1391 if (local->mode() == LET || local->mode() == CONST || |
| 1393 local->mode() == CONST_LEGACY) { | 1392 local->mode() == CONST_LEGACY) { |
| 1394 __ cmp(eax, isolate()->factory()->the_hole_value()); | 1393 __ cmp(eax, isolate()->factory()->the_hole_value()); |
| 1395 __ j(not_equal, done); | 1394 __ j(not_equal, done); |
| 1396 if (local->mode() == CONST_LEGACY) { | 1395 if (local->mode() == CONST_LEGACY) { |
| 1397 __ mov(eax, isolate()->factory()->undefined_value()); | 1396 __ mov(eax, isolate()->factory()->undefined_value()); |
| 1398 } else { // LET || CONST | 1397 } else { // LET || CONST |
| 1399 __ push(Immediate(var->name())); | 1398 __ push(Immediate(var->name())); |
| 1400 __ CallRuntime(Runtime::kThrowReferenceError, 1); | 1399 __ CallRuntime(Runtime::kThrowReferenceError, 1); |
| 1401 } | 1400 } |
| 1402 } | 1401 } |
| 1403 __ jmp(done); | 1402 __ jmp(done); |
| 1404 } | 1403 } |
| 1405 } | 1404 } |
| 1406 | 1405 |
| 1407 | 1406 |
| 1408 void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, | 1407 void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, |
| 1409 TypeofState typeof_state) { | 1408 TypeofMode typeof_mode) { |
| 1410 Variable* var = proxy->var(); | 1409 Variable* var = proxy->var(); |
| 1411 DCHECK(var->IsUnallocatedOrGlobalSlot() || | 1410 DCHECK(var->IsUnallocatedOrGlobalSlot() || |
| 1412 (var->IsLookupSlot() && var->mode() == DYNAMIC_GLOBAL)); | 1411 (var->IsLookupSlot() && var->mode() == DYNAMIC_GLOBAL)); |
| 1413 if (var->IsGlobalSlot()) { | 1412 if (var->IsGlobalSlot()) { |
| 1414 DCHECK(var->index() > 0); | 1413 DCHECK(var->index() > 0); |
| 1415 DCHECK(var->IsStaticGlobalObjectProperty()); | 1414 DCHECK(var->IsStaticGlobalObjectProperty()); |
| 1416 // Each var occupies two slots in the context: for reads and writes. | 1415 // Each var occupies two slots in the context: for reads and writes. |
| 1417 int slot_index = var->index(); | 1416 int slot_index = var->index(); |
| 1418 int depth = scope()->ContextChainLength(var->scope()); | 1417 int depth = scope()->ContextChainLength(var->scope()); |
| 1419 __ mov(LoadGlobalViaContextDescriptor::DepthRegister(), | 1418 __ mov(LoadGlobalViaContextDescriptor::DepthRegister(), |
| 1420 Immediate(Smi::FromInt(depth))); | 1419 Immediate(Smi::FromInt(depth))); |
| 1421 __ mov(LoadGlobalViaContextDescriptor::SlotRegister(), | 1420 __ mov(LoadGlobalViaContextDescriptor::SlotRegister(), |
| 1422 Immediate(Smi::FromInt(slot_index))); | 1421 Immediate(Smi::FromInt(slot_index))); |
| 1423 __ mov(LoadGlobalViaContextDescriptor::NameRegister(), var->name()); | 1422 __ mov(LoadGlobalViaContextDescriptor::NameRegister(), var->name()); |
| 1424 LoadGlobalViaContextStub stub(isolate(), depth); | 1423 LoadGlobalViaContextStub stub(isolate(), depth); |
| 1425 __ CallStub(&stub); | 1424 __ CallStub(&stub); |
| 1426 | 1425 |
| 1427 } else { | 1426 } else { |
| 1428 __ mov(LoadDescriptor::ReceiverRegister(), GlobalObjectOperand()); | 1427 __ mov(LoadDescriptor::ReceiverRegister(), GlobalObjectOperand()); |
| 1429 __ mov(LoadDescriptor::NameRegister(), var->name()); | 1428 __ mov(LoadDescriptor::NameRegister(), var->name()); |
| 1430 __ mov(LoadDescriptor::SlotRegister(), | 1429 __ mov(LoadDescriptor::SlotRegister(), |
| 1431 Immediate(SmiFromSlot(proxy->VariableFeedbackSlot()))); | 1430 Immediate(SmiFromSlot(proxy->VariableFeedbackSlot()))); |
| 1432 // Inside typeof use a regular load, not a contextual load, to avoid | 1431 CallLoadIC(typeof_mode); |
| 1433 // a reference error. | |
| 1434 CallLoadIC(typeof_state == NOT_INSIDE_TYPEOF ? CONTEXTUAL : NOT_CONTEXTUAL); | |
| 1435 } | 1432 } |
| 1436 } | 1433 } |
| 1437 | 1434 |
| 1438 | 1435 |
| 1439 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, | 1436 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, |
| 1440 TypeofState typeof_state) { | 1437 TypeofMode typeof_mode) { |
| 1441 SetExpressionPosition(proxy); | 1438 SetExpressionPosition(proxy); |
| 1442 PrepareForBailoutForId(proxy->BeforeId(), NO_REGISTERS); | 1439 PrepareForBailoutForId(proxy->BeforeId(), NO_REGISTERS); |
| 1443 Variable* var = proxy->var(); | 1440 Variable* var = proxy->var(); |
| 1444 | 1441 |
| 1445 // Three cases: global variables, lookup variables, and all other types of | 1442 // Three cases: global variables, lookup variables, and all other types of |
| 1446 // variables. | 1443 // variables. |
| 1447 switch (var->location()) { | 1444 switch (var->location()) { |
| 1448 case VariableLocation::GLOBAL: | 1445 case VariableLocation::GLOBAL: |
| 1449 case VariableLocation::UNALLOCATED: { | 1446 case VariableLocation::UNALLOCATED: { |
| 1450 Comment cmnt(masm_, "[ Global variable"); | 1447 Comment cmnt(masm_, "[ Global variable"); |
| 1451 EmitGlobalVariableLoad(proxy, typeof_state); | 1448 EmitGlobalVariableLoad(proxy, typeof_mode); |
| 1452 context()->Plug(eax); | 1449 context()->Plug(eax); |
| 1453 break; | 1450 break; |
| 1454 } | 1451 } |
| 1455 | 1452 |
| 1456 case VariableLocation::PARAMETER: | 1453 case VariableLocation::PARAMETER: |
| 1457 case VariableLocation::LOCAL: | 1454 case VariableLocation::LOCAL: |
| 1458 case VariableLocation::CONTEXT: { | 1455 case VariableLocation::CONTEXT: { |
| 1459 DCHECK_EQ(NOT_INSIDE_TYPEOF, typeof_state); | 1456 DCHECK_EQ(NOT_INSIDE_TYPEOF, typeof_mode); |
| 1460 Comment cmnt(masm_, var->IsContextSlot() ? "[ Context variable" | 1457 Comment cmnt(masm_, var->IsContextSlot() ? "[ Context variable" |
| 1461 : "[ Stack variable"); | 1458 : "[ Stack variable"); |
| 1462 if (var->binding_needs_init()) { | 1459 if (var->binding_needs_init()) { |
| 1463 // var->scope() may be NULL when the proxy is located in eval code and | 1460 // var->scope() may be NULL when the proxy is located in eval code and |
| 1464 // refers to a potential outside binding. Currently those bindings are | 1461 // refers to a potential outside binding. Currently those bindings are |
| 1465 // always looked up dynamically, i.e. in that case | 1462 // always looked up dynamically, i.e. in that case |
| 1466 // var->location() == LOOKUP. | 1463 // var->location() == LOOKUP. |
| 1467 // always holds. | 1464 // always holds. |
| 1468 DCHECK(var->scope() != NULL); | 1465 DCHECK(var->scope() != NULL); |
| 1469 | 1466 |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1522 } | 1519 } |
| 1523 context()->Plug(var); | 1520 context()->Plug(var); |
| 1524 break; | 1521 break; |
| 1525 } | 1522 } |
| 1526 | 1523 |
| 1527 case VariableLocation::LOOKUP: { | 1524 case VariableLocation::LOOKUP: { |
| 1528 Comment cmnt(masm_, "[ Lookup variable"); | 1525 Comment cmnt(masm_, "[ Lookup variable"); |
| 1529 Label done, slow; | 1526 Label done, slow; |
| 1530 // Generate code for loading from variables potentially shadowed | 1527 // Generate code for loading from variables potentially shadowed |
| 1531 // by eval-introduced variables. | 1528 // by eval-introduced variables. |
| 1532 EmitDynamicLookupFastCase(proxy, typeof_state, &slow, &done); | 1529 EmitDynamicLookupFastCase(proxy, typeof_mode, &slow, &done); |
| 1533 __ bind(&slow); | 1530 __ bind(&slow); |
| 1534 __ push(esi); // Context. | 1531 __ push(esi); // Context. |
| 1535 __ push(Immediate(var->name())); | 1532 __ push(Immediate(var->name())); |
| 1536 Runtime::FunctionId function_id = | 1533 Runtime::FunctionId function_id = |
| 1537 typeof_state == NOT_INSIDE_TYPEOF | 1534 typeof_mode == NOT_INSIDE_TYPEOF |
| 1538 ? Runtime::kLoadLookupSlot | 1535 ? Runtime::kLoadLookupSlot |
| 1539 : Runtime::kLoadLookupSlotNoReferenceError; | 1536 : Runtime::kLoadLookupSlotNoReferenceError; |
| 1540 __ CallRuntime(function_id, 2); | 1537 __ CallRuntime(function_id, 2); |
| 1541 __ bind(&done); | 1538 __ bind(&done); |
| 1542 context()->Plug(eax); | 1539 context()->Plug(eax); |
| 1543 break; | 1540 break; |
| 1544 } | 1541 } |
| 1545 } | 1542 } |
| 1546 } | 1543 } |
| 1547 | 1544 |
| (...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2208 __ Drop(1); // The function is still on the stack; drop it. | 2205 __ Drop(1); // The function is still on the stack; drop it. |
| 2209 | 2206 |
| 2210 // if (!result.done) goto l_try; | 2207 // if (!result.done) goto l_try; |
| 2211 __ bind(&l_loop); | 2208 __ bind(&l_loop); |
| 2212 __ push(eax); // save result | 2209 __ push(eax); // save result |
| 2213 __ Move(load_receiver, eax); // result | 2210 __ Move(load_receiver, eax); // result |
| 2214 __ mov(load_name, | 2211 __ mov(load_name, |
| 2215 isolate()->factory()->done_string()); // "done" | 2212 isolate()->factory()->done_string()); // "done" |
| 2216 __ mov(LoadDescriptor::SlotRegister(), | 2213 __ mov(LoadDescriptor::SlotRegister(), |
| 2217 Immediate(SmiFromSlot(expr->DoneFeedbackSlot()))); | 2214 Immediate(SmiFromSlot(expr->DoneFeedbackSlot()))); |
| 2218 CallLoadIC(NOT_CONTEXTUAL); // result.done in eax | 2215 CallLoadIC(NOT_INSIDE_TYPEOF); // result.done in eax |
| 2219 Handle<Code> bool_ic = ToBooleanStub::GetUninitialized(isolate()); | 2216 Handle<Code> bool_ic = ToBooleanStub::GetUninitialized(isolate()); |
| 2220 CallIC(bool_ic); | 2217 CallIC(bool_ic); |
| 2221 __ test(eax, eax); | 2218 __ test(eax, eax); |
| 2222 __ j(zero, &l_try); | 2219 __ j(zero, &l_try); |
| 2223 | 2220 |
| 2224 // result.value | 2221 // result.value |
| 2225 __ pop(load_receiver); // result | 2222 __ pop(load_receiver); // result |
| 2226 __ mov(load_name, | 2223 __ mov(load_name, |
| 2227 isolate()->factory()->value_string()); // "value" | 2224 isolate()->factory()->value_string()); // "value" |
| 2228 __ mov(LoadDescriptor::SlotRegister(), | 2225 __ mov(LoadDescriptor::SlotRegister(), |
| 2229 Immediate(SmiFromSlot(expr->ValueFeedbackSlot()))); | 2226 Immediate(SmiFromSlot(expr->ValueFeedbackSlot()))); |
| 2230 CallLoadIC(NOT_CONTEXTUAL); // result.value in eax | 2227 CallLoadIC(NOT_INSIDE_TYPEOF); // result.value in eax |
| 2231 context()->DropAndPlug(2, eax); // drop iter and g | 2228 context()->DropAndPlug(2, eax); // drop iter and g |
| 2232 break; | 2229 break; |
| 2233 } | 2230 } |
| 2234 } | 2231 } |
| 2235 } | 2232 } |
| 2236 | 2233 |
| 2237 | 2234 |
| 2238 void FullCodeGenerator::EmitGeneratorResume(Expression *generator, | 2235 void FullCodeGenerator::EmitGeneratorResume(Expression *generator, |
| 2239 Expression *value, | 2236 Expression *value, |
| 2240 JSGeneratorObject::ResumeMode resume_mode) { | 2237 JSGeneratorObject::ResumeMode resume_mode) { |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2359 | 2356 |
| 2360 void FullCodeGenerator::EmitNamedPropertyLoad(Property* prop) { | 2357 void FullCodeGenerator::EmitNamedPropertyLoad(Property* prop) { |
| 2361 SetExpressionPosition(prop); | 2358 SetExpressionPosition(prop); |
| 2362 Literal* key = prop->key()->AsLiteral(); | 2359 Literal* key = prop->key()->AsLiteral(); |
| 2363 DCHECK(!key->value()->IsSmi()); | 2360 DCHECK(!key->value()->IsSmi()); |
| 2364 DCHECK(!prop->IsSuperAccess()); | 2361 DCHECK(!prop->IsSuperAccess()); |
| 2365 | 2362 |
| 2366 __ mov(LoadDescriptor::NameRegister(), Immediate(key->value())); | 2363 __ mov(LoadDescriptor::NameRegister(), Immediate(key->value())); |
| 2367 __ mov(LoadDescriptor::SlotRegister(), | 2364 __ mov(LoadDescriptor::SlotRegister(), |
| 2368 Immediate(SmiFromSlot(prop->PropertyFeedbackSlot()))); | 2365 Immediate(SmiFromSlot(prop->PropertyFeedbackSlot()))); |
| 2369 CallLoadIC(NOT_CONTEXTUAL, language_mode()); | 2366 CallLoadIC(NOT_INSIDE_TYPEOF, language_mode()); |
| 2370 } | 2367 } |
| 2371 | 2368 |
| 2372 | 2369 |
| 2373 void FullCodeGenerator::EmitNamedSuperPropertyLoad(Property* prop) { | 2370 void FullCodeGenerator::EmitNamedSuperPropertyLoad(Property* prop) { |
| 2374 // Stack: receiver, home_object. | 2371 // Stack: receiver, home_object. |
| 2375 SetExpressionPosition(prop); | 2372 SetExpressionPosition(prop); |
| 2376 Literal* key = prop->key()->AsLiteral(); | 2373 Literal* key = prop->key()->AsLiteral(); |
| 2377 DCHECK(!key->value()->IsSmi()); | 2374 DCHECK(!key->value()->IsSmi()); |
| 2378 DCHECK(prop->IsSuperAccess()); | 2375 DCHECK(prop->IsSuperAccess()); |
| 2379 | 2376 |
| (...skipping 2290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4670 void FullCodeGenerator::EmitLoadJSRuntimeFunction(CallRuntime* expr) { | 4667 void FullCodeGenerator::EmitLoadJSRuntimeFunction(CallRuntime* expr) { |
| 4671 // Push the builtins object as receiver. | 4668 // Push the builtins object as receiver. |
| 4672 __ mov(eax, GlobalObjectOperand()); | 4669 __ mov(eax, GlobalObjectOperand()); |
| 4673 __ push(FieldOperand(eax, GlobalObject::kBuiltinsOffset)); | 4670 __ push(FieldOperand(eax, GlobalObject::kBuiltinsOffset)); |
| 4674 | 4671 |
| 4675 // Load the function from the receiver. | 4672 // Load the function from the receiver. |
| 4676 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); | 4673 __ mov(LoadDescriptor::ReceiverRegister(), Operand(esp, 0)); |
| 4677 __ mov(LoadDescriptor::NameRegister(), Immediate(expr->name())); | 4674 __ mov(LoadDescriptor::NameRegister(), Immediate(expr->name())); |
| 4678 __ mov(LoadDescriptor::SlotRegister(), | 4675 __ mov(LoadDescriptor::SlotRegister(), |
| 4679 Immediate(SmiFromSlot(expr->CallRuntimeFeedbackSlot()))); | 4676 Immediate(SmiFromSlot(expr->CallRuntimeFeedbackSlot()))); |
| 4680 CallLoadIC(NOT_CONTEXTUAL); | 4677 CallLoadIC(NOT_INSIDE_TYPEOF); |
| 4681 } | 4678 } |
| 4682 | 4679 |
| 4683 | 4680 |
| 4684 void FullCodeGenerator::EmitCallJSRuntimeFunction(CallRuntime* expr) { | 4681 void FullCodeGenerator::EmitCallJSRuntimeFunction(CallRuntime* expr) { |
| 4685 ZoneList<Expression*>* args = expr->arguments(); | 4682 ZoneList<Expression*>* args = expr->arguments(); |
| 4686 int arg_count = args->length(); | 4683 int arg_count = args->length(); |
| 4687 | 4684 |
| 4688 SetExpressionPosition(expr); | 4685 SetExpressionPosition(expr); |
| 4689 CallFunctionStub stub(isolate(), arg_count, NO_CALL_FUNCTION_FLAGS); | 4686 CallFunctionStub stub(isolate(), arg_count, NO_CALL_FUNCTION_FLAGS); |
| 4690 __ mov(edi, Operand(esp, (arg_count + 1) * kPointerSize)); | 4687 __ mov(edi, Operand(esp, (arg_count + 1) * kPointerSize)); |
| (...skipping 792 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5483 Assembler::target_address_at(call_target_address, | 5480 Assembler::target_address_at(call_target_address, |
| 5484 unoptimized_code)); | 5481 unoptimized_code)); |
| 5485 return OSR_AFTER_STACK_CHECK; | 5482 return OSR_AFTER_STACK_CHECK; |
| 5486 } | 5483 } |
| 5487 | 5484 |
| 5488 | 5485 |
| 5489 } // namespace internal | 5486 } // namespace internal |
| 5490 } // namespace v8 | 5487 } // namespace v8 |
| 5491 | 5488 |
| 5492 #endif // V8_TARGET_ARCH_X87 | 5489 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |