| 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 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 FOR_EACH_COMPUTATION(DECLARE_VISIT_COMPUTATION) | 63 FOR_EACH_COMPUTATION(DECLARE_VISIT_COMPUTATION) |
| 64 FOR_EACH_INSTRUCTION(DECLARE_VISIT_INSTRUCTION) | 64 FOR_EACH_INSTRUCTION(DECLARE_VISIT_INSTRUCTION) |
| 65 | 65 |
| 66 #undef DECLARE_VISIT_COMPUTATION | 66 #undef DECLARE_VISIT_COMPUTATION |
| 67 #undef DECLARE_VISIT_INSTRUCTION | 67 #undef DECLARE_VISIT_INSTRUCTION |
| 68 | 68 |
| 69 // Emit code to load a Value into register 'dst'. | 69 // Emit code to load a Value into register 'dst'. |
| 70 void LoadValue(Register dst, Value* value); | 70 void LoadValue(Register dst, Value* value); |
| 71 | 71 |
| 72 // Emit an instance call. | 72 // Emit an instance call. |
| 73 void EmitInstanceCall(intptr_t node_id, | 73 void EmitInstanceCall(intptr_t cid, |
| 74 intptr_t token_index, | 74 intptr_t token_index, |
| 75 intptr_t try_index, | 75 intptr_t try_index, |
| 76 const String& function_name, | 76 const String& function_name, |
| 77 intptr_t argument_count, | 77 intptr_t argument_count, |
| 78 const Array& argument_names, | 78 const Array& argument_names, |
| 79 intptr_t checked_argument_count); | 79 intptr_t checked_argument_count); |
| 80 | 80 |
| 81 // Emit a static call. | 81 // Emit a static call. |
| 82 void EmitStaticCall(intptr_t token_index, | 82 void EmitStaticCall(intptr_t token_index, |
| 83 intptr_t try_index, | 83 intptr_t try_index, |
| 84 const Function& function, | 84 const Function& function, |
| 85 intptr_t argument_count, | 85 intptr_t argument_count, |
| 86 const Array& argument_names); | 86 const Array& argument_names); |
| 87 | 87 |
| 88 // Infrastructure copied from class CodeGenerator. | 88 // Infrastructure copied from class CodeGenerator. |
| 89 void GenerateCall(intptr_t token_index, | 89 void GenerateCall(intptr_t token_index, |
| 90 intptr_t try_index, | 90 intptr_t try_index, |
| 91 const ExternalLabel* label, | 91 const ExternalLabel* label, |
| 92 PcDescriptors::Kind kind); | 92 PcDescriptors::Kind kind); |
| 93 void GenerateCallRuntime(intptr_t node_id, | 93 void GenerateCallRuntime(intptr_t cid, |
| 94 intptr_t token_index, | 94 intptr_t token_index, |
| 95 intptr_t try_index, | 95 intptr_t try_index, |
| 96 const RuntimeEntry& entry); | 96 const RuntimeEntry& entry); |
| 97 void AddCurrentDescriptor(PcDescriptors::Kind kind, | 97 void AddCurrentDescriptor(PcDescriptors::Kind kind, |
| 98 intptr_t node_id, | 98 intptr_t cid, |
| 99 intptr_t token_index, | 99 intptr_t token_index, |
| 100 intptr_t try_index); | 100 intptr_t try_index); |
| 101 | 101 |
| 102 void GenerateInlineInstanceof(const AbstractType& type, | 102 void GenerateInlineInstanceof(const AbstractType& type, |
| 103 Label* is_instance, | 103 Label* is_instance, |
| 104 Label* is_not_instance); | 104 Label* is_not_instance); |
| 105 | 105 |
| 106 void GenerateAssertAssignable(intptr_t node_id, | 106 void GenerateAssertAssignable(intptr_t cid, |
| 107 intptr_t token_index, | 107 intptr_t token_index, |
| 108 intptr_t try_index, | 108 intptr_t try_index, |
| 109 const AbstractType& dst_type, | 109 const AbstractType& dst_type, |
| 110 const String& dst_name); | 110 const String& dst_name); |
| 111 | 111 |
| 112 void GenerateInstanceOf(intptr_t node_id, | 112 void GenerateInstanceOf(intptr_t cid, |
| 113 intptr_t token_index, | 113 intptr_t token_index, |
| 114 intptr_t try_index, | 114 intptr_t try_index, |
| 115 const AbstractType& type, | 115 const AbstractType& type, |
| 116 bool negate_result); | 116 bool negate_result); |
| 117 | 117 |
| 118 void CopyParameters(); | 118 void CopyParameters(); |
| 119 | 119 |
| 120 intptr_t StackSize() const; | 120 intptr_t StackSize() const; |
| 121 | 121 |
| 122 bool TryIntrinsify(); | 122 bool TryIntrinsify(); |
| (...skipping 11 matching lines...) Expand all Loading... |
| 134 BlockEntryInstr* current_block_; | 134 BlockEntryInstr* current_block_; |
| 135 DescriptorList* pc_descriptors_list_; | 135 DescriptorList* pc_descriptors_list_; |
| 136 ExceptionHandlerList* exception_handlers_list_; | 136 ExceptionHandlerList* exception_handlers_list_; |
| 137 | 137 |
| 138 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); | 138 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); |
| 139 }; | 139 }; |
| 140 | 140 |
| 141 } // namespace dart | 141 } // namespace dart |
| 142 | 142 |
| 143 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ | 143 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ |
| OLD | NEW |