| 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_X64 | 7 #if V8_TARGET_ARCH_X64 |
| 8 | 8 |
| 9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
| 10 #include "src/ic-inl.h" | 10 #include "src/ic-inl.h" |
| (...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 965 GenerateMiss(masm); | 965 GenerateMiss(masm); |
| 966 } | 966 } |
| 967 | 967 |
| 968 | 968 |
| 969 void LoadIC::GenerateNormal(MacroAssembler* masm) { | 969 void LoadIC::GenerateNormal(MacroAssembler* masm) { |
| 970 // ----------- S t a t e ------------- | 970 // ----------- S t a t e ------------- |
| 971 // -- rax : receiver | 971 // -- rax : receiver |
| 972 // -- rcx : name | 972 // -- rcx : name |
| 973 // -- rsp[0] : return address | 973 // -- rsp[0] : return address |
| 974 // ----------------------------------- | 974 // ----------------------------------- |
| 975 Label miss; | 975 Label miss, slow; |
| 976 | 976 |
| 977 GenerateNameDictionaryReceiverCheck(masm, rax, rdx, rbx, &miss); | 977 GenerateNameDictionaryReceiverCheck(masm, rax, rdx, rbx, &miss); |
| 978 | 978 |
| 979 // rdx: elements | 979 // rdx: elements |
| 980 // Search the dictionary placing the result in rax. | 980 // Search the dictionary placing the result in rax. |
| 981 GenerateDictionaryLoad(masm, &miss, rdx, rcx, rbx, rdi, rax); | 981 GenerateDictionaryLoad(masm, &slow, rdx, rcx, rbx, rdi, rax); |
| 982 __ ret(0); | 982 __ ret(0); |
| 983 | 983 |
| 984 // Dictionary load failed, go slow (but don't miss). |
| 985 __ bind(&slow); |
| 986 GenerateRuntimeGetProperty(masm); |
| 987 |
| 984 // Cache miss: Jump to runtime. | 988 // Cache miss: Jump to runtime. |
| 985 __ bind(&miss); | 989 __ bind(&miss); |
| 986 GenerateMiss(masm); | 990 GenerateMiss(masm); |
| 987 } | 991 } |
| 988 | 992 |
| 989 | 993 |
| 990 void LoadIC::GenerateMiss(MacroAssembler* masm) { | 994 void LoadIC::GenerateMiss(MacroAssembler* masm) { |
| 991 // ----------- S t a t e ------------- | 995 // ----------- S t a t e ------------- |
| 992 // -- rax : receiver | 996 // -- rax : receiver |
| 993 // -- rcx : name | 997 // -- rcx : name |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1298 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) | 1302 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) |
| 1299 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) | 1303 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) |
| 1300 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); | 1304 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); |
| 1301 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); | 1305 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); |
| 1302 } | 1306 } |
| 1303 | 1307 |
| 1304 | 1308 |
| 1305 } } // namespace v8::internal | 1309 } } // namespace v8::internal |
| 1306 | 1310 |
| 1307 #endif // V8_TARGET_ARCH_X64 | 1311 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |