| 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_H_ | 5 #ifndef VM_FLOW_GRAPH_COMPILER_H_ |
| 6 #define VM_FLOW_GRAPH_COMPILER_H_ | 6 #define VM_FLOW_GRAPH_COMPILER_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/assembler.h" | 9 #include "vm/assembler.h" |
| 10 #include "vm/code_descriptors.h" | 10 #include "vm/code_descriptors.h" |
| (...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 494 const Function& target, | 494 const Function& target, |
| 495 const Array& arguments_descriptor, | 495 const Array& arguments_descriptor, |
| 496 intptr_t num_args_tested); | 496 intptr_t num_args_tested); |
| 497 | 497 |
| 498 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data() const { | 498 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data() const { |
| 499 return *deopt_id_to_ic_data_; | 499 return *deopt_id_to_ic_data_; |
| 500 } | 500 } |
| 501 | 501 |
| 502 Isolate* isolate() const { return isolate_; } | 502 Isolate* isolate() const { return isolate_; } |
| 503 | 503 |
| 504 void AddStubCallTarget(const Code& code); |
| 505 |
| 504 private: | 506 private: |
| 505 friend class CheckStackOverflowSlowPath; // For pending_deoptimization_env_. | 507 friend class CheckStackOverflowSlowPath; // For pending_deoptimization_env_. |
| 506 | 508 |
| 507 void EmitFrameEntry(); | 509 void EmitFrameEntry(); |
| 508 | 510 |
| 509 void AddStaticCallTarget(const Function& function); | 511 void AddStaticCallTarget(const Function& function); |
| 510 | 512 |
| 511 void GenerateDeferredCode(); | 513 void GenerateDeferredCode(); |
| 512 | 514 |
| 513 void EmitInstructionPrologue(Instruction* instr); | 515 void EmitInstructionPrologue(Instruction* instr); |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 616 // Compiler specific per-block state. Indexed by postorder block number | 618 // Compiler specific per-block state. Indexed by postorder block number |
| 617 // for convenience. This is not the block's index in the block order, | 619 // for convenience. This is not the block's index in the block order, |
| 618 // which is reverse postorder. | 620 // which is reverse postorder. |
| 619 BlockEntryInstr* current_block_; | 621 BlockEntryInstr* current_block_; |
| 620 ExceptionHandlerList* exception_handlers_list_; | 622 ExceptionHandlerList* exception_handlers_list_; |
| 621 DescriptorList* pc_descriptors_list_; | 623 DescriptorList* pc_descriptors_list_; |
| 622 StackmapTableBuilder* stackmap_table_builder_; | 624 StackmapTableBuilder* stackmap_table_builder_; |
| 623 GrowableArray<BlockInfo*> block_info_; | 625 GrowableArray<BlockInfo*> block_info_; |
| 624 GrowableArray<CompilerDeoptInfo*> deopt_infos_; | 626 GrowableArray<CompilerDeoptInfo*> deopt_infos_; |
| 625 GrowableArray<SlowPathCode*> slow_path_code_; | 627 GrowableArray<SlowPathCode*> slow_path_code_; |
| 626 // Stores: [code offset, function, null(code)]. | 628 // Stores: [code offset, function or null, null(code)]. |
| 629 // Stores static call targets as well as stub targets. |
| 630 // TODO(srdjan): Evaluate if we should store allocation stub targets into a |
| 631 // separate table? |
| 627 const GrowableObjectArray& static_calls_target_table_; | 632 const GrowableObjectArray& static_calls_target_table_; |
| 628 const bool is_optimizing_; | 633 const bool is_optimizing_; |
| 629 // Set to true if optimized code has IC calls. | 634 // Set to true if optimized code has IC calls. |
| 630 bool may_reoptimize_; | 635 bool may_reoptimize_; |
| 631 // True while emitting intrinsic code. | 636 // True while emitting intrinsic code. |
| 632 bool intrinsic_mode_; | 637 bool intrinsic_mode_; |
| 633 Label intrinsic_slow_path_label_; | 638 Label intrinsic_slow_path_label_; |
| 634 | 639 |
| 635 const Class& double_class_; | 640 const Class& double_class_; |
| 636 const Class& mint_class_; | 641 const Class& mint_class_; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 652 intptr_t lazy_deopt_pc_offset_; | 657 intptr_t lazy_deopt_pc_offset_; |
| 653 | 658 |
| 654 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data_; | 659 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data_; |
| 655 | 660 |
| 656 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); | 661 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); |
| 657 }; | 662 }; |
| 658 | 663 |
| 659 } // namespace dart | 664 } // namespace dart |
| 660 | 665 |
| 661 #endif // VM_FLOW_GRAPH_COMPILER_H_ | 666 #endif // VM_FLOW_GRAPH_COMPILER_H_ |
| OLD | NEW |