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_CRANKSHAFT_LITHIUM_H_ | 5 #ifndef V8_CRANKSHAFT_LITHIUM_H_ |
6 #define V8_CRANKSHAFT_LITHIUM_H_ | 6 #define V8_CRANKSHAFT_LITHIUM_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
653 void AddGapMove(int index, LOperand* from, LOperand* to); | 653 void AddGapMove(int index, LOperand* from, LOperand* to); |
654 LGap* GetGapAt(int index) const; | 654 LGap* GetGapAt(int index) const; |
655 bool IsGapAt(int index) const; | 655 bool IsGapAt(int index) const; |
656 int NearestGapPos(int index) const; | 656 int NearestGapPos(int index) const; |
657 void MarkEmptyBlocks(); | 657 void MarkEmptyBlocks(); |
658 const ZoneList<LPointerMap*>* pointer_maps() const { return &pointer_maps_; } | 658 const ZoneList<LPointerMap*>* pointer_maps() const { return &pointer_maps_; } |
659 LLabel* GetLabel(int block_id) const; | 659 LLabel* GetLabel(int block_id) const; |
660 int LookupDestination(int block_id) const; | 660 int LookupDestination(int block_id) const; |
661 Label* GetAssemblyLabel(int block_id) const; | 661 Label* GetAssemblyLabel(int block_id) const; |
662 | 662 |
663 const ZoneList<Handle<SharedFunctionInfo>>& inlined_functions() const { | |
664 return inlined_functions_; | |
665 } | |
666 | |
667 void AddInlinedFunction(Handle<SharedFunctionInfo> closure) { | |
668 inlined_functions_.Add(closure, zone()); | |
669 } | |
670 | |
671 void AddDeprecationDependency(Handle<Map> map) { | 663 void AddDeprecationDependency(Handle<Map> map) { |
672 DCHECK(!map->is_deprecated()); | 664 DCHECK(!map->is_deprecated()); |
673 if (!map->CanBeDeprecated()) return; | 665 if (!map->CanBeDeprecated()) return; |
674 DCHECK(!info_->IsStub()); | 666 DCHECK(!info_->IsStub()); |
675 deprecation_dependencies_.Add(map, zone()); | 667 deprecation_dependencies_.Add(map, zone()); |
676 } | 668 } |
677 | 669 |
678 void AddStabilityDependency(Handle<Map> map) { | 670 void AddStabilityDependency(Handle<Map> map) { |
679 DCHECK(map->is_stable()); | 671 DCHECK(map->is_stable()); |
680 if (!map->CanTransition()) return; | 672 if (!map->CanTransition()) return; |
(...skipping 17 matching lines...) Expand all Loading... |
698 int current_frame_slots_; | 690 int current_frame_slots_; |
699 | 691 |
700 private: | 692 private: |
701 void CommitDependencies(Handle<Code> code) const; | 693 void CommitDependencies(Handle<Code> code) const; |
702 | 694 |
703 CompilationInfo* info_; | 695 CompilationInfo* info_; |
704 HGraph* const graph_; | 696 HGraph* const graph_; |
705 BitVector* allocated_double_registers_; | 697 BitVector* allocated_double_registers_; |
706 ZoneList<LInstruction*> instructions_; | 698 ZoneList<LInstruction*> instructions_; |
707 ZoneList<LPointerMap*> pointer_maps_; | 699 ZoneList<LPointerMap*> pointer_maps_; |
708 ZoneList<Handle<SharedFunctionInfo>> inlined_functions_; | |
709 ZoneList<Handle<Map>> deprecation_dependencies_; | 700 ZoneList<Handle<Map>> deprecation_dependencies_; |
710 ZoneList<Handle<Map>> stability_dependencies_; | 701 ZoneList<Handle<Map>> stability_dependencies_; |
711 }; | 702 }; |
712 | 703 |
713 | 704 |
714 class LChunkBuilderBase BASE_EMBEDDED { | 705 class LChunkBuilderBase BASE_EMBEDDED { |
715 public: | 706 public: |
716 explicit LChunkBuilderBase(CompilationInfo* info, HGraph* graph) | 707 explicit LChunkBuilderBase(CompilationInfo* info, HGraph* graph) |
717 : argument_count_(0), | 708 : argument_count_(0), |
718 chunk_(NULL), | 709 chunk_(NULL), |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
847 InputIterator input_iterator_; | 838 InputIterator input_iterator_; |
848 DeepIterator env_iterator_; | 839 DeepIterator env_iterator_; |
849 }; | 840 }; |
850 | 841 |
851 class LInstruction; | 842 class LInstruction; |
852 class LCodeGen; | 843 class LCodeGen; |
853 } // namespace internal | 844 } // namespace internal |
854 } // namespace v8 | 845 } // namespace v8 |
855 | 846 |
856 #endif // V8_CRANKSHAFT_LITHIUM_H_ | 847 #endif // V8_CRANKSHAFT_LITHIUM_H_ |
OLD | NEW |