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

Side by Side Diff: src/mips/ic-mips.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/ic.cc ('k') | src/mips/stub-cache-mips.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 808 matching lines...) Expand 10 before | Expand all | Expand 10 after
819 __ bind(&notin); 819 __ bind(&notin);
820 // The unmapped lookup expects that the parameter map is in a2. 820 // The unmapped lookup expects that the parameter map is in a2.
821 MemOperand unmapped_location = 821 MemOperand unmapped_location =
822 GenerateUnmappedArgumentsLookup(masm, a0, a2, a3, &slow); 822 GenerateUnmappedArgumentsLookup(masm, a0, a2, a3, &slow);
823 __ lw(a2, unmapped_location); 823 __ lw(a2, unmapped_location);
824 __ LoadRoot(a3, Heap::kTheHoleValueRootIndex); 824 __ LoadRoot(a3, Heap::kTheHoleValueRootIndex);
825 __ Branch(&slow, eq, a2, Operand(a3)); 825 __ Branch(&slow, eq, a2, Operand(a3));
826 __ Ret(USE_DELAY_SLOT); 826 __ Ret(USE_DELAY_SLOT);
827 __ mov(v0, a2); 827 __ mov(v0, a2);
828 __ bind(&slow); 828 __ bind(&slow);
829 GenerateMiss(masm, MISS); 829 GenerateMiss(masm);
830 } 830 }
831 831
832 832
833 void KeyedStoreIC::GenerateNonStrictArguments(MacroAssembler* masm) { 833 void KeyedStoreIC::GenerateNonStrictArguments(MacroAssembler* masm) {
834 // ---------- S t a t e -------------- 834 // ---------- S t a t e --------------
835 // -- a0 : value 835 // -- a0 : value
836 // -- a1 : key 836 // -- a1 : key
837 // -- a2 : receiver 837 // -- a2 : receiver
838 // -- lr : return address 838 // -- lr : return address
839 // ----------------------------------- 839 // -----------------------------------
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
884 GenerateUnmappedArgumentsLookup(masm, a2, a3, t0, &slow); 884 GenerateUnmappedArgumentsLookup(masm, a2, a3, t0, &slow);
885 __ lw(a1, unmapped_location); 885 __ lw(a1, unmapped_location);
886 __ LoadRoot(a3, Heap::kTheHoleValueRootIndex); 886 __ LoadRoot(a3, Heap::kTheHoleValueRootIndex);
887 __ Branch(&slow, eq, a1, Operand(a3)); 887 __ Branch(&slow, eq, a1, Operand(a3));
888 GenerateFunctionTailCall(masm, argc, &slow, a3); 888 GenerateFunctionTailCall(masm, argc, &slow, a3);
889 __ bind(&slow); 889 __ bind(&slow);
890 GenerateMiss(masm, argc); 890 GenerateMiss(masm, argc);
891 } 891 }
892 892
893 893
894 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm, ICMissMode miss_mode) { 894 void KeyedLoadIC::GenerateMiss(MacroAssembler* masm) {
895 // ---------- S t a t e -------------- 895 // ---------- S t a t e --------------
896 // -- ra : return address 896 // -- ra : return address
897 // -- a0 : key 897 // -- a0 : key
898 // -- a1 : receiver 898 // -- a1 : receiver
899 // ----------------------------------- 899 // -----------------------------------
900 Isolate* isolate = masm->isolate(); 900 Isolate* isolate = masm->isolate();
901 901
902 __ IncrementCounter(isolate->counters()->keyed_load_miss(), 1, a3, t0); 902 __ IncrementCounter(isolate->counters()->keyed_load_miss(), 1, a3, t0);
903 903
904 __ Push(a1, a0); 904 __ Push(a1, a0);
905 905
906 // Perform tail call to the entry. 906 // Perform tail call to the entry.
907 ExternalReference ref = miss_mode == MISS_FORCE_GENERIC 907 ExternalReference ref =
908 ? ExternalReference(IC_Utility(kKeyedLoadIC_MissForceGeneric), isolate) 908 ExternalReference(IC_Utility(kKeyedLoadIC_Miss), isolate);
909 : ExternalReference(IC_Utility(kKeyedLoadIC_Miss), isolate);
910 909
911 __ TailCallExternalReference(ref, 2, 1); 910 __ TailCallExternalReference(ref, 2, 1);
912 } 911 }
913 912
914 913
915 void KeyedLoadIC::GenerateRuntimeGetProperty(MacroAssembler* masm) { 914 void KeyedLoadIC::GenerateRuntimeGetProperty(MacroAssembler* masm) {
916 // ---------- S t a t e -------------- 915 // ---------- S t a t e --------------
917 // -- ra : return address 916 // -- ra : return address
918 // -- a0 : key 917 // -- a0 : key
919 // -- a1 : receiver 918 // -- a1 : receiver
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
1124 &miss, // When not a number. 1123 &miss, // When not a number.
1125 &miss, // When index out of range. 1124 &miss, // When index out of range.
1126 STRING_INDEX_IS_ARRAY_INDEX); 1125 STRING_INDEX_IS_ARRAY_INDEX);
1127 char_at_generator.GenerateFast(masm); 1126 char_at_generator.GenerateFast(masm);
1128 __ Ret(); 1127 __ Ret();
1129 1128
1130 StubRuntimeCallHelper call_helper; 1129 StubRuntimeCallHelper call_helper;
1131 char_at_generator.GenerateSlow(masm, call_helper); 1130 char_at_generator.GenerateSlow(masm, call_helper);
1132 1131
1133 __ bind(&miss); 1132 __ bind(&miss);
1134 GenerateMiss(masm, MISS); 1133 GenerateMiss(masm);
1135 } 1134 }
1136 1135
1137 1136
1138 void KeyedStoreIC::GenerateRuntimeSetProperty(MacroAssembler* masm, 1137 void KeyedStoreIC::GenerateRuntimeSetProperty(MacroAssembler* masm,
1139 StrictModeFlag strict_mode) { 1138 StrictModeFlag strict_mode) {
1140 // ---------- S t a t e -------------- 1139 // ---------- S t a t e --------------
1141 // -- a0 : value 1140 // -- a0 : value
1142 // -- a1 : key 1141 // -- a1 : key
1143 // -- a2 : receiver 1142 // -- a2 : receiver
1144 // -- ra : return address 1143 // -- ra : return address
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
1446 __ And(a3, a3, Operand(kSlowCaseBitFieldMask)); 1445 __ And(a3, a3, Operand(kSlowCaseBitFieldMask));
1447 __ Branch(&slow, ne, a3, Operand(1 << Map::kHasIndexedInterceptor)); 1446 __ Branch(&slow, ne, a3, Operand(1 << Map::kHasIndexedInterceptor));
1448 // Everything is fine, call runtime. 1447 // Everything is fine, call runtime.
1449 __ Push(a1, a0); // Receiver, key. 1448 __ Push(a1, a0); // Receiver, key.
1450 1449
1451 // Perform tail call to the entry. 1450 // Perform tail call to the entry.
1452 __ TailCallExternalReference(ExternalReference( 1451 __ TailCallExternalReference(ExternalReference(
1453 IC_Utility(kKeyedLoadPropertyWithInterceptor), masm->isolate()), 2, 1); 1452 IC_Utility(kKeyedLoadPropertyWithInterceptor), masm->isolate()), 2, 1);
1454 1453
1455 __ bind(&slow); 1454 __ bind(&slow);
1456 GenerateMiss(masm, MISS); 1455 GenerateMiss(masm);
1457 } 1456 }
1458 1457
1459 1458
1460 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) { 1459 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) {
1461 // ---------- S t a t e -------------- 1460 // ---------- S t a t e --------------
1462 // -- a0 : value 1461 // -- a0 : value
1463 // -- a1 : key 1462 // -- a1 : key
1464 // -- a2 : receiver 1463 // -- a2 : receiver
1465 // -- ra : return address 1464 // -- ra : return address
1466 // ----------------------------------- 1465 // -----------------------------------
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
1688 } else { 1687 } else {
1689 ASSERT(Assembler::IsBne(branch_instr)); 1688 ASSERT(Assembler::IsBne(branch_instr));
1690 patcher.ChangeBranchCondition(eq); 1689 patcher.ChangeBranchCondition(eq);
1691 } 1690 }
1692 } 1691 }
1693 1692
1694 1693
1695 } } // namespace v8::internal 1694 } } // namespace v8::internal
1696 1695
1697 #endif // V8_TARGET_ARCH_MIPS 1696 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/ic.cc ('k') | src/mips/stub-cache-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698