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 21 matching lines...) Expand all Loading... |
32 | 32 |
33 void CompileGraph(); | 33 void CompileGraph(); |
34 | 34 |
35 // Infrastructure copied from class CodeGenerator or stubbed out. | 35 // Infrastructure copied from class CodeGenerator or stubbed out. |
36 void FinalizePcDescriptors(const Code& code); | 36 void FinalizePcDescriptors(const Code& code); |
37 void FinalizeStackmaps(const Code& code); | 37 void FinalizeStackmaps(const Code& code); |
38 void FinalizeVarDescriptors(const Code& code); | 38 void FinalizeVarDescriptors(const Code& code); |
39 void FinalizeExceptionHandlers(const Code& code); | 39 void FinalizeExceptionHandlers(const Code& code); |
40 | 40 |
41 private: | 41 private: |
| 42 // Constructor is lighweight, major initialization work should occur here. |
| 43 // This makes it easier to measure time spent in the compiler. |
| 44 void InitCompiler(); |
| 45 |
42 struct BlockInfo : public ZoneAllocated { | 46 struct BlockInfo : public ZoneAllocated { |
43 public: | 47 public: |
44 BlockInfo() : label() { } | 48 BlockInfo() : label() { } |
45 | 49 |
46 Label label; | 50 Label label; |
47 }; | 51 }; |
48 | 52 |
49 BlockEntryInstr* current_block() const { return current_block_; } | 53 BlockEntryInstr* current_block() const { return current_block_; } |
50 | 54 |
51 bool is_optimizing() const { return is_optimizing_; } | 55 bool is_optimizing() const { return is_optimizing_; } |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 DescriptorList* pc_descriptors_list_; | 142 DescriptorList* pc_descriptors_list_; |
139 ExceptionHandlerList* exception_handlers_list_; | 143 ExceptionHandlerList* exception_handlers_list_; |
140 const bool is_optimizing_; | 144 const bool is_optimizing_; |
141 | 145 |
142 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); | 146 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); |
143 }; | 147 }; |
144 | 148 |
145 } // namespace dart | 149 } // namespace dart |
146 | 150 |
147 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ | 151 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ |
OLD | NEW |