| 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 #ifndef V8_CODE_FACTORY_H_ | 5 #ifndef V8_CODE_FACTORY_H_ |
| 6 #define V8_CODE_FACTORY_H_ | 6 #define V8_CODE_FACTORY_H_ |
| 7 | 7 |
| 8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
| 9 #include "src/assembler.h" | 9 #include "src/assembler.h" |
| 10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 : code_(code), descriptor_(descriptor) {} | 21 : code_(code), descriptor_(descriptor) {} |
| 22 | 22 |
| 23 Handle<Code> code() const { return code_; } | 23 Handle<Code> code() const { return code_; } |
| 24 CallInterfaceDescriptor descriptor() const { return descriptor_; } | 24 CallInterfaceDescriptor descriptor() const { return descriptor_; } |
| 25 | 25 |
| 26 private: | 26 private: |
| 27 const Handle<Code> code_; | 27 const Handle<Code> code_; |
| 28 const CallInterfaceDescriptor descriptor_; | 28 const CallInterfaceDescriptor descriptor_; |
| 29 }; | 29 }; |
| 30 | 30 |
| 31 | 31 class V8_EXPORT_PRIVATE CodeFactory final { |
| 32 class CodeFactory final { | |
| 33 public: | 32 public: |
| 34 // Initial states for ICs. | 33 // Initial states for ICs. |
| 35 static Callable LoadIC(Isolate* isolate); | 34 static Callable LoadIC(Isolate* isolate); |
| 36 static Callable LoadICInOptimizedCode(Isolate* isolate); | 35 static Callable LoadICInOptimizedCode(Isolate* isolate); |
| 37 static Callable LoadGlobalIC(Isolate* isolate, TypeofMode typeof_mode); | 36 static Callable LoadGlobalIC(Isolate* isolate, TypeofMode typeof_mode); |
| 38 static Callable LoadGlobalICInOptimizedCode(Isolate* isolate, | 37 static Callable LoadGlobalICInOptimizedCode(Isolate* isolate, |
| 39 TypeofMode typeof_mode); | 38 TypeofMode typeof_mode); |
| 40 static Callable KeyedLoadIC(Isolate* isolate); | 39 static Callable KeyedLoadIC(Isolate* isolate); |
| 41 static Callable KeyedLoadICInOptimizedCode(Isolate* isolate); | 40 static Callable KeyedLoadICInOptimizedCode(Isolate* isolate); |
| 42 static Callable KeyedLoadIC_Megamorphic(Isolate* isolate); | 41 static Callable KeyedLoadIC_Megamorphic(Isolate* isolate); |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 Isolate* isolate, CallableType function_type = CallableType::kAny); | 162 Isolate* isolate, CallableType function_type = CallableType::kAny); |
| 164 static Callable InterpreterPushArgsAndConstructArray(Isolate* isolate); | 163 static Callable InterpreterPushArgsAndConstructArray(Isolate* isolate); |
| 165 static Callable InterpreterCEntry(Isolate* isolate, int result_size = 1); | 164 static Callable InterpreterCEntry(Isolate* isolate, int result_size = 1); |
| 166 static Callable InterpreterOnStackReplacement(Isolate* isolate); | 165 static Callable InterpreterOnStackReplacement(Isolate* isolate); |
| 167 }; | 166 }; |
| 168 | 167 |
| 169 } // namespace internal | 168 } // namespace internal |
| 170 } // namespace v8 | 169 } // namespace v8 |
| 171 | 170 |
| 172 #endif // V8_CODE_FACTORY_H_ | 171 #endif // V8_CODE_FACTORY_H_ |
| OLD | NEW |