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

Side by Side Diff: src/x64/ic-x64.cc

Issue 68213024: Remove keyed load "force generic" miss case. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/x64/stub-cache-x64.cc » ('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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
533 &miss, // When not a number. 533 &miss, // When not a number.
534 &miss, // When index out of range. 534 &miss, // When index out of range.
535 STRING_INDEX_IS_ARRAY_INDEX); 535 STRING_INDEX_IS_ARRAY_INDEX);
536 char_at_generator.GenerateFast(masm); 536 char_at_generator.GenerateFast(masm);
537 __ ret(0); 537 __ ret(0);
538 538
539 StubRuntimeCallHelper call_helper; 539 StubRuntimeCallHelper call_helper;
540 char_at_generator.GenerateSlow(masm, call_helper); 540 char_at_generator.GenerateSlow(masm, call_helper);
541 541
542 __ bind(&miss); 542 __ bind(&miss);
543 GenerateMiss(masm, MISS); 543 GenerateMiss(masm);
544 } 544 }
545 545
546 546
547 void KeyedLoadIC::GenerateIndexedInterceptor(MacroAssembler* masm) { 547 void KeyedLoadIC::GenerateIndexedInterceptor(MacroAssembler* masm) {
548 // ----------- S t a t e ------------- 548 // ----------- S t a t e -------------
549 // -- rax : key 549 // -- rax : key
550 // -- rdx : receiver 550 // -- rdx : receiver
551 // -- rsp[0] : return address 551 // -- rsp[0] : return address
552 // ----------------------------------- 552 // -----------------------------------
553 Label slow; 553 Label slow;
(...skipping 22 matching lines...) Expand all
576 __ PushReturnAddressFrom(rcx); 576 __ PushReturnAddressFrom(rcx);
577 577
578 // Perform tail call to the entry. 578 // Perform tail call to the entry.
579 __ TailCallExternalReference( 579 __ TailCallExternalReference(
580 ExternalReference(IC_Utility(kKeyedLoadPropertyWithInterceptor), 580 ExternalReference(IC_Utility(kKeyedLoadPropertyWithInterceptor),
581 masm->isolate()), 581 masm->isolate()),
582 2, 582 2,
583 1); 583 1);
584 584
585 __ bind(&slow); 585 __ bind(&slow);
586 GenerateMiss(masm, MISS); 586 GenerateMiss(masm);
587 } 587 }
588 588
589 589
590 static void KeyedStoreGenerateGenericHelper( 590 static void KeyedStoreGenerateGenericHelper(
591 MacroAssembler* masm, 591 MacroAssembler* masm,
592 Label* fast_object, 592 Label* fast_object,
593 Label* fast_double, 593 Label* fast_double,
594 Label* slow, 594 Label* slow,
595 KeyedStoreCheckMap check_map, 595 KeyedStoreCheckMap check_map,
596 KeyedStoreIncrementLength increment_length) { 596 KeyedStoreIncrementLength increment_length) {
(...skipping 667 matching lines...) Expand 10 before | Expand all | Expand 10 after
1264 __ Ret(); 1264 __ Ret();
1265 __ bind(&notin); 1265 __ bind(&notin);
1266 // The unmapped lookup expects that the parameter map is in rbx. 1266 // The unmapped lookup expects that the parameter map is in rbx.
1267 Operand unmapped_location = 1267 Operand unmapped_location =
1268 GenerateUnmappedArgumentsLookup(masm, rax, rbx, rcx, &slow); 1268 GenerateUnmappedArgumentsLookup(masm, rax, rbx, rcx, &slow);
1269 __ CompareRoot(unmapped_location, Heap::kTheHoleValueRootIndex); 1269 __ CompareRoot(unmapped_location, Heap::kTheHoleValueRootIndex);
1270 __ j(equal, &slow); 1270 __ j(equal, &slow);
1271 __ movq(rax, unmapped_location); 1271 __ movq(rax, unmapped_location);
1272 __ Ret(); 1272 __ Ret();
1273 __ bind(&slow); 1273 __ bind(&slow);
1274 GenerateMiss(masm, MISS); 1274 GenerateMiss(masm);
1275 } 1275 }
1276 1276
1277 1277
1278 void KeyedStoreIC::GenerateNonStrictArguments(MacroAssembler* masm) { 1278 void KeyedStoreIC::GenerateNonStrictArguments(MacroAssembler* masm) {
1279 // ----------- S t a t e ------------- 1279 // ----------- S t a t e -------------
1280 // -- rax : value 1280 // -- rax : value
1281 // -- rcx : key 1281 // -- rcx : key
1282 // -- rdx : receiver 1282 // -- rdx : receiver
1283 // -- rsp[0] : return address 1283 // -- rsp[0] : return address
1284 // ----------------------------------- 1284 // -----------------------------------
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
1416 __ PopReturnAddressTo(rbx); 1416 __ PopReturnAddressTo(rbx);
1417 __ push(rax); // receiver 1417 __ push(rax); // receiver
1418 __ push(rcx); // name 1418 __ push(rcx); // name
1419 __ PushReturnAddressFrom(rbx); 1419 __ PushReturnAddressFrom(rbx);
1420 1420
1421 // Perform tail call to the entry. 1421 // Perform tail call to the entry.
1422 __ TailCallRuntime(Runtime::kGetProperty, 2, 1); 1422 __ TailCallRuntime(Runtime::kGetProperty, 2, 1);
1423 } 1423 }
1424 1424
1425 1425
1426 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm, ICMissMode miss_mode) { 1426 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm) {
1427 // ----------- S t a t e ------------- 1427 // ----------- S t a t e -------------
1428 // -- rax : key 1428 // -- rax : key
1429 // -- rdx : receiver 1429 // -- rdx : receiver
1430 // -- rsp[0] : return address 1430 // -- rsp[0] : return address
1431 // ----------------------------------- 1431 // -----------------------------------
1432 1432
1433 Counters* counters = masm->isolate()->counters(); 1433 Counters* counters = masm->isolate()->counters();
1434 __ IncrementCounter(counters->keyed_load_miss(), 1); 1434 __ IncrementCounter(counters->keyed_load_miss(), 1);
1435 1435
1436 __ PopReturnAddressTo(rbx); 1436 __ PopReturnAddressTo(rbx);
1437 __ push(rdx); // receiver 1437 __ push(rdx); // receiver
1438 __ push(rax); // name 1438 __ push(rax); // name
1439 __ PushReturnAddressFrom(rbx); 1439 __ PushReturnAddressFrom(rbx);
1440 1440
1441 // Perform tail call to the entry. 1441 // Perform tail call to the entry.
1442 ExternalReference ref = miss_mode == MISS_FORCE_GENERIC 1442 ExternalReference ref =
1443 ? ExternalReference(IC_Utility(kKeyedLoadIC_MissForceGeneric), 1443 ExternalReference(IC_Utility(kKeyedLoadIC_Miss), masm->isolate());
1444 masm->isolate())
1445 : ExternalReference(IC_Utility(kKeyedLoadIC_Miss), masm->isolate());
1446 __ TailCallExternalReference(ref, 2, 1); 1444 __ TailCallExternalReference(ref, 2, 1);
1447 } 1445 }
1448 1446
1449 1447
1450 void KeyedLoadIC::GenerateRuntimeGetProperty(MacroAssembler* masm) { 1448 void KeyedLoadIC::GenerateRuntimeGetProperty(MacroAssembler* masm) {
1451 // ----------- S t a t e ------------- 1449 // ----------- S t a t e -------------
1452 // -- rax : key 1450 // -- rax : key
1453 // -- rdx : receiver 1451 // -- rdx : receiver
1454 // -- rsp[0] : return address 1452 // -- rsp[0] : return address
1455 // ----------------------------------- 1453 // -----------------------------------
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
1700 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) 1698 Condition cc = (check == ENABLE_INLINED_SMI_CHECK)
1701 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) 1699 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero)
1702 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); 1700 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry);
1703 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); 1701 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc);
1704 } 1702 }
1705 1703
1706 1704
1707 } } // namespace v8::internal 1705 } } // namespace v8::internal
1708 1706
1709 #endif // V8_TARGET_ARCH_X64 1707 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/x64/stub-cache-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698