OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/code-factory.h" | 5 #include "src/code-factory.h" |
6 | 6 |
7 #include "src/bootstrapper.h" | 7 #include "src/bootstrapper.h" |
8 #include "src/ic/ic.h" | 8 #include "src/ic/ic.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 TailCallMode tail_call_mode) { | 77 TailCallMode tail_call_mode) { |
78 return Callable(CallIC::initialize_stub_in_optimized_code(isolate, argc, mode, | 78 return Callable(CallIC::initialize_stub_in_optimized_code(isolate, argc, mode, |
79 tail_call_mode), | 79 tail_call_mode), |
80 CallFunctionWithFeedbackAndVectorDescriptor(isolate)); | 80 CallFunctionWithFeedbackAndVectorDescriptor(isolate)); |
81 } | 81 } |
82 | 82 |
83 | 83 |
84 // static | 84 // static |
85 Callable CodeFactory::StoreIC(Isolate* isolate, LanguageMode language_mode) { | 85 Callable CodeFactory::StoreIC(Isolate* isolate, LanguageMode language_mode) { |
86 StoreICTrampolineStub stub(isolate, StoreICState(language_mode)); | 86 StoreICTrampolineStub stub(isolate, StoreICState(language_mode)); |
87 return Callable(stub.GetCode(), VectorStoreICTrampolineDescriptor(isolate)); | 87 return Callable(stub.GetCode(), StoreDescriptor(isolate)); |
88 } | 88 } |
89 | 89 |
90 | 90 |
91 // static | 91 // static |
92 Callable CodeFactory::StoreICInOptimizedCode(Isolate* isolate, | 92 Callable CodeFactory::StoreICInOptimizedCode(Isolate* isolate, |
93 LanguageMode language_mode) { | 93 LanguageMode language_mode) { |
94 CallInterfaceDescriptor descriptor = VectorStoreICDescriptor(isolate); | 94 CallInterfaceDescriptor descriptor = StoreWithVectorDescriptor(isolate); |
95 return Callable( | 95 return Callable( |
96 StoreIC::initialize_stub_in_optimized_code(isolate, language_mode), | 96 StoreIC::initialize_stub_in_optimized_code(isolate, language_mode), |
97 descriptor); | 97 descriptor); |
98 } | 98 } |
99 | 99 |
100 | 100 |
101 // static | 101 // static |
102 Callable CodeFactory::KeyedStoreIC(Isolate* isolate, | 102 Callable CodeFactory::KeyedStoreIC(Isolate* isolate, |
103 LanguageMode language_mode) { | 103 LanguageMode language_mode) { |
104 KeyedStoreICTrampolineStub stub(isolate, StoreICState(language_mode)); | 104 KeyedStoreICTrampolineStub stub(isolate, StoreICState(language_mode)); |
105 return Callable(stub.GetCode(), VectorStoreICTrampolineDescriptor(isolate)); | 105 return Callable(stub.GetCode(), StoreDescriptor(isolate)); |
106 } | 106 } |
107 | 107 |
108 | 108 |
109 // static | 109 // static |
110 Callable CodeFactory::KeyedStoreICInOptimizedCode(Isolate* isolate, | 110 Callable CodeFactory::KeyedStoreICInOptimizedCode(Isolate* isolate, |
111 LanguageMode language_mode) { | 111 LanguageMode language_mode) { |
112 CallInterfaceDescriptor descriptor = VectorStoreICDescriptor(isolate); | 112 CallInterfaceDescriptor descriptor = StoreWithVectorDescriptor(isolate); |
113 return Callable( | 113 return Callable( |
114 KeyedStoreIC::initialize_stub_in_optimized_code(isolate, language_mode), | 114 KeyedStoreIC::initialize_stub_in_optimized_code(isolate, language_mode), |
115 descriptor); | 115 descriptor); |
116 } | 116 } |
117 | 117 |
118 | 118 |
119 // static | 119 // static |
120 Callable CodeFactory::CompareIC(Isolate* isolate, Token::Value op) { | 120 Callable CodeFactory::CompareIC(Isolate* isolate, Token::Value op) { |
121 Handle<Code> code = CompareIC::GetUninitialized(isolate, op); | 121 Handle<Code> code = CompareIC::GetUninitialized(isolate, op); |
122 return Callable(code, CompareDescriptor(isolate)); | 122 return Callable(code, CompareDescriptor(isolate)); |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
590 // static | 590 // static |
591 Callable CodeFactory::InterpreterCEntry(Isolate* isolate, int result_size) { | 591 Callable CodeFactory::InterpreterCEntry(Isolate* isolate, int result_size) { |
592 // Note: If we ever use fpregs in the interpreter then we will need to | 592 // Note: If we ever use fpregs in the interpreter then we will need to |
593 // save fpregs too. | 593 // save fpregs too. |
594 CEntryStub stub(isolate, result_size, kDontSaveFPRegs, kArgvInRegister); | 594 CEntryStub stub(isolate, result_size, kDontSaveFPRegs, kArgvInRegister); |
595 return Callable(stub.GetCode(), InterpreterCEntryDescriptor(isolate)); | 595 return Callable(stub.GetCode(), InterpreterCEntryDescriptor(isolate)); |
596 } | 596 } |
597 | 597 |
598 } // namespace internal | 598 } // namespace internal |
599 } // namespace v8 | 599 } // namespace v8 |
OLD | NEW |