OLD | NEW |
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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 Isolate* isolate, | 68 Isolate* isolate, |
69 CodeStubInterfaceDescriptor* descriptor) { | 69 CodeStubInterfaceDescriptor* descriptor) { |
70 static Register registers[] = { rdx, rax }; | 70 static Register registers[] = { rdx, rax }; |
71 descriptor->register_param_count_ = 2; | 71 descriptor->register_param_count_ = 2; |
72 descriptor->register_params_ = registers; | 72 descriptor->register_params_ = registers; |
73 descriptor->deoptimization_handler_ = | 73 descriptor->deoptimization_handler_ = |
74 FUNCTION_ADDR(KeyedLoadIC_MissFromStubFailure); | 74 FUNCTION_ADDR(KeyedLoadIC_MissFromStubFailure); |
75 } | 75 } |
76 | 76 |
77 | 77 |
| 78 void LoadFieldStub::InitializeInterfaceDescriptor( |
| 79 Isolate* isolate, |
| 80 CodeStubInterfaceDescriptor* descriptor) { |
| 81 static Register registers[] = { rax }; |
| 82 descriptor->register_param_count_ = 1; |
| 83 descriptor->register_params_ = registers; |
| 84 descriptor->stack_parameter_count_ = NULL; |
| 85 descriptor->deoptimization_handler_ = NULL; |
| 86 } |
| 87 |
| 88 |
| 89 void KeyedLoadFieldStub::InitializeInterfaceDescriptor( |
| 90 Isolate* isolate, |
| 91 CodeStubInterfaceDescriptor* descriptor) { |
| 92 static Register registers[] = { rdx }; |
| 93 descriptor->register_param_count_ = 1; |
| 94 descriptor->register_params_ = registers; |
| 95 descriptor->stack_parameter_count_ = NULL; |
| 96 descriptor->deoptimization_handler_ = NULL; |
| 97 } |
| 98 |
| 99 |
78 void KeyedStoreFastElementStub::InitializeInterfaceDescriptor( | 100 void KeyedStoreFastElementStub::InitializeInterfaceDescriptor( |
79 Isolate* isolate, | 101 Isolate* isolate, |
80 CodeStubInterfaceDescriptor* descriptor) { | 102 CodeStubInterfaceDescriptor* descriptor) { |
81 static Register registers[] = { rdx, rcx, rax }; | 103 static Register registers[] = { rdx, rcx, rax }; |
82 descriptor->register_param_count_ = 3; | 104 descriptor->register_param_count_ = 3; |
83 descriptor->register_params_ = registers; | 105 descriptor->register_params_ = registers; |
84 descriptor->deoptimization_handler_ = | 106 descriptor->deoptimization_handler_ = |
85 FUNCTION_ADDR(KeyedStoreIC_MissFromStubFailure); | 107 FUNCTION_ADDR(KeyedStoreIC_MissFromStubFailure); |
86 } | 108 } |
87 | 109 |
(...skipping 2297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2385 ExternalReference ref = | 2407 ExternalReference ref = |
2386 ExternalReference(IC_Utility(IC::kStoreIC_ArrayLength), masm->isolate()); | 2408 ExternalReference(IC_Utility(IC::kStoreIC_ArrayLength), masm->isolate()); |
2387 __ TailCallExternalReference(ref, 2, 1); | 2409 __ TailCallExternalReference(ref, 2, 1); |
2388 | 2410 |
2389 __ bind(&miss); | 2411 __ bind(&miss); |
2390 | 2412 |
2391 StubCompiler::TailCallBuiltin(masm, StubCompiler::MissBuiltin(kind())); | 2413 StubCompiler::TailCallBuiltin(masm, StubCompiler::MissBuiltin(kind())); |
2392 } | 2414 } |
2393 | 2415 |
2394 | 2416 |
2395 void LoadFieldStub::Generate(MacroAssembler* masm) { | |
2396 StubCompiler::DoGenerateFastPropertyLoad(masm, rax, reg_, inobject_, index_); | |
2397 __ ret(0); | |
2398 } | |
2399 | |
2400 | |
2401 void ArgumentsAccessStub::GenerateReadElement(MacroAssembler* masm) { | 2417 void ArgumentsAccessStub::GenerateReadElement(MacroAssembler* masm) { |
2402 // The key is in rdx and the parameter count is in rax. | 2418 // The key is in rdx and the parameter count is in rax. |
2403 | 2419 |
2404 // The displacement is used for skipping the frame pointer on the | 2420 // The displacement is used for skipping the frame pointer on the |
2405 // stack. It is the offset of the last parameter (if any) relative | 2421 // stack. It is the offset of the last parameter (if any) relative |
2406 // to the frame pointer. | 2422 // to the frame pointer. |
2407 static const int kDisplacement = 1 * kPointerSize; | 2423 static const int kDisplacement = 1 * kPointerSize; |
2408 | 2424 |
2409 // Check that the key is a smi. | 2425 // Check that the key is a smi. |
2410 Label slow; | 2426 Label slow; |
(...skipping 4540 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6951 __ jmp(generic_construct_stub, RelocInfo::CODE_TARGET); | 6967 __ jmp(generic_construct_stub, RelocInfo::CODE_TARGET); |
6952 } | 6968 } |
6953 } | 6969 } |
6954 | 6970 |
6955 | 6971 |
6956 #undef __ | 6972 #undef __ |
6957 | 6973 |
6958 } } // namespace v8::internal | 6974 } } // namespace v8::internal |
6959 | 6975 |
6960 #endif // V8_TARGET_ARCH_X64 | 6976 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |