| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_FLOW_GRAPH_COMPILER_X64_H_ | 5 #ifndef VM_FLOW_GRAPH_COMPILER_X64_H_ |
| 6 #define VM_FLOW_GRAPH_COMPILER_X64_H_ | 6 #define VM_FLOW_GRAPH_COMPILER_X64_H_ |
| 7 | 7 |
| 8 #ifndef VM_FLOW_GRAPH_COMPILER_H_ | 8 #ifndef VM_FLOW_GRAPH_COMPILER_H_ |
| 9 #error Include flow_graph_compiler.h instead of flow_graph_compiler_x64.h. | 9 #error Include flow_graph_compiler.h instead of flow_graph_compiler_x64.h. |
| 10 #endif | 10 #endif |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 const GrowableArray<BlockEntryInstr*>& block_order, | 31 const GrowableArray<BlockEntryInstr*>& block_order, |
| 32 bool is_optimizing); | 32 bool is_optimizing); |
| 33 | 33 |
| 34 void CompileGraph(); | 34 void CompileGraph(); |
| 35 | 35 |
| 36 void GenerateCallRuntime(intptr_t cid, | 36 void GenerateCallRuntime(intptr_t cid, |
| 37 intptr_t token_index, | 37 intptr_t token_index, |
| 38 intptr_t try_index, | 38 intptr_t try_index, |
| 39 const RuntimeEntry& entry); | 39 const RuntimeEntry& entry); |
| 40 | 40 |
| 41 // Infrastructure copied from class CodeGenerator. |
| 42 void GenerateCall(intptr_t token_index, |
| 43 intptr_t try_index, |
| 44 const ExternalLabel* label, |
| 45 PcDescriptors::Kind kind); |
| 46 |
| 41 private: | 47 private: |
| 42 friend class DeoptimizationStub; | 48 friend class DeoptimizationStub; |
| 43 | 49 |
| 44 // TODO(fschneider): Clean up friend-class declarations once all code | 50 // TODO(fschneider): Clean up friend-class declarations once all code |
| 45 // generator templates have been moved to intermediate_language_x64.cc. | 51 // generator templates have been moved to intermediate_language_x64.cc. |
| 46 #define DECLARE_FRIEND(ShortName, ClassName) friend class ClassName; | 52 #define DECLARE_FRIEND(ShortName, ClassName) friend class ClassName; |
| 47 FOR_EACH_COMPUTATION(DECLARE_FRIEND) | 53 FOR_EACH_COMPUTATION(DECLARE_FRIEND) |
| 48 #undef DECLARE_FRIEND | 54 #undef DECLARE_FRIEND |
| 49 | 55 |
| 50 static const int kLocalsOffsetFromFP = (-1 * kWordSize); | 56 static const int kLocalsOffsetFromFP = (-1 * kWordSize); |
| (...skipping 13 matching lines...) Expand all Loading... |
| 64 const ICData& ic_data, | 70 const ICData& ic_data, |
| 65 const Array& arguments_descriptor, | 71 const Array& arguments_descriptor, |
| 66 intptr_t argument_count); | 72 intptr_t argument_count); |
| 67 | 73 |
| 68 // Returns pc-offset (in bytes) of the pc after the call, can be used to emit | 74 // Returns pc-offset (in bytes) of the pc after the call, can be used to emit |
| 69 // pc-descriptor information. | 75 // pc-descriptor information. |
| 70 virtual intptr_t EmitStaticCall(const Function& function, | 76 virtual intptr_t EmitStaticCall(const Function& function, |
| 71 const Array& arguments_descriptor, | 77 const Array& arguments_descriptor, |
| 72 intptr_t argument_count); | 78 intptr_t argument_count); |
| 73 | 79 |
| 74 // Infrastructure copied from class CodeGenerator. | |
| 75 void GenerateCall(intptr_t token_index, | |
| 76 intptr_t try_index, | |
| 77 const ExternalLabel* label, | |
| 78 PcDescriptors::Kind kind); | |
| 79 | |
| 80 // Type checking helper methods. | 80 // Type checking helper methods. |
| 81 virtual void CheckClassIds(Register class_id_reg, | 81 virtual void CheckClassIds(Register class_id_reg, |
| 82 const GrowableArray<intptr_t>& class_ids, | 82 const GrowableArray<intptr_t>& class_ids, |
| 83 Label* is_instance_lbl, | 83 Label* is_instance_lbl, |
| 84 Label* is_not_instance_lbl); | 84 Label* is_not_instance_lbl); |
| 85 | 85 |
| 86 RawSubtypeTestCache* GenerateInlineInstanceof(intptr_t cid, | 86 RawSubtypeTestCache* GenerateInlineInstanceof(intptr_t cid, |
| 87 intptr_t token_index, | 87 intptr_t token_index, |
| 88 const AbstractType& type, | 88 const AbstractType& type, |
| 89 Label* is_instance_lbl, | 89 Label* is_instance_lbl, |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 | 147 |
| 148 virtual void GenerateInlinedGetter(intptr_t offset); | 148 virtual void GenerateInlinedGetter(intptr_t offset); |
| 149 virtual void GenerateInlinedSetter(intptr_t offset); | 149 virtual void GenerateInlinedSetter(intptr_t offset); |
| 150 | 150 |
| 151 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); | 151 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); |
| 152 }; | 152 }; |
| 153 | 153 |
| 154 } // namespace dart | 154 } // namespace dart |
| 155 | 155 |
| 156 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ | 156 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ |
| OLD | NEW |