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

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

Issue 166883002: Remove HandlerKindField and just encode the handlerkind as the only extra-ic-state. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 10 months 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
« src/objects.h ('K') | « src/stub-cache.cc ('k') | no next file » | 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 955 matching lines...) Expand 10 before | Expand all | Expand 10 after
966 r8, 966 r8,
967 kDontSaveFPRegs, 967 kDontSaveFPRegs,
968 EMIT_REMEMBERED_SET, 968 EMIT_REMEMBERED_SET,
969 INLINE_SMI_CHECK); 969 INLINE_SMI_CHECK);
970 __ Ret(); 970 __ Ret();
971 __ bind(&slow); 971 __ bind(&slow);
972 GenerateMiss(masm); 972 GenerateMiss(masm);
973 } 973 }
974 974
975 975
976 void LoadIC::GenerateMegamorphic(MacroAssembler* masm, 976 void LoadIC::GenerateMegamorphic(MacroAssembler* masm) {
977 ExtraICState extra_state) {
978 // ----------- S t a t e ------------- 977 // ----------- S t a t e -------------
979 // -- rax : receiver 978 // -- rax : receiver
980 // -- rcx : name 979 // -- rcx : name
981 // -- rsp[0] : return address 980 // -- rsp[0] : return address
982 // ----------------------------------- 981 // -----------------------------------
983 982
984 // Probe the stub cache. 983 // Probe the stub cache.
985 Code::Flags flags = Code::ComputeHandlerFlags(Code::LOAD_IC, extra_state); 984 Code::Flags flags = Code::ComputeHandlerFlags(Code::LOAD_IC);
986 masm->isolate()->stub_cache()->GenerateProbe( 985 masm->isolate()->stub_cache()->GenerateProbe(
987 masm, flags, rax, rcx, rbx, rdx); 986 masm, flags, rax, rcx, rbx, rdx);
988 987
989 GenerateMiss(masm); 988 GenerateMiss(masm);
990 } 989 }
991 990
992 991
993 void LoadIC::GenerateNormal(MacroAssembler* masm) { 992 void LoadIC::GenerateNormal(MacroAssembler* masm) {
994 // ----------- S t a t e ------------- 993 // ----------- S t a t e -------------
995 // -- rax : receiver 994 // -- rax : receiver
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
1082 __ PopReturnAddressTo(rbx); 1081 __ PopReturnAddressTo(rbx);
1083 __ push(rdx); // receiver 1082 __ push(rdx); // receiver
1084 __ push(rax); // name 1083 __ push(rax); // name
1085 __ PushReturnAddressFrom(rbx); 1084 __ PushReturnAddressFrom(rbx);
1086 1085
1087 // Perform tail call to the entry. 1086 // Perform tail call to the entry.
1088 __ TailCallRuntime(Runtime::kKeyedGetProperty, 2, 1); 1087 __ TailCallRuntime(Runtime::kKeyedGetProperty, 2, 1);
1089 } 1088 }
1090 1089
1091 1090
1092 void StoreIC::GenerateMegamorphic(MacroAssembler* masm, 1091 void StoreIC::GenerateMegamorphic(MacroAssembler* masm) {
1093 ExtraICState extra_state) {
1094 // ----------- S t a t e ------------- 1092 // ----------- S t a t e -------------
1095 // -- rax : value 1093 // -- rax : value
1096 // -- rcx : name 1094 // -- rcx : name
1097 // -- rdx : receiver 1095 // -- rdx : receiver
1098 // -- rsp[0] : return address 1096 // -- rsp[0] : return address
1099 // ----------------------------------- 1097 // -----------------------------------
1100 1098
1101 // Get the receiver from the stack and probe the stub cache. 1099 // Get the receiver from the stack and probe the stub cache.
1102 Code::Flags flags = Code::ComputeHandlerFlags(Code::STORE_IC, extra_state); 1100 Code::Flags flags = Code::ComputeHandlerFlags(Code::STORE_IC);
1103 masm->isolate()->stub_cache()->GenerateProbe( 1101 masm->isolate()->stub_cache()->GenerateProbe(
1104 masm, flags, rdx, rcx, rbx, no_reg); 1102 masm, flags, rdx, rcx, rbx, no_reg);
1105 1103
1106 // Cache miss: Jump to runtime. 1104 // Cache miss: Jump to runtime.
1107 GenerateMiss(masm); 1105 GenerateMiss(masm);
1108 } 1106 }
1109 1107
1110 1108
1111 void StoreIC::GenerateMiss(MacroAssembler* masm) { 1109 void StoreIC::GenerateMiss(MacroAssembler* masm) {
1112 // ----------- S t a t e ------------- 1110 // ----------- S t a t e -------------
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
1323 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) 1321 Condition cc = (check == ENABLE_INLINED_SMI_CHECK)
1324 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) 1322 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero)
1325 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); 1323 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry);
1326 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); 1324 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc);
1327 } 1325 }
1328 1326
1329 1327
1330 } } // namespace v8::internal 1328 } } // namespace v8::internal
1331 1329
1332 #endif // V8_TARGET_ARCH_X64 1330 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/objects.h ('K') | « src/stub-cache.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698