778 }; |
778 }; |
779 |
779 |
780 //------------------------------AbstractLockNode----------------------------------- |
780 //------------------------------AbstractLockNode----------------------------------- |
781 class AbstractLockNode: public CallNode { |
781 class AbstractLockNode: public CallNode { |
782 private: |
782 private: |
783 bool _eliminate; // indicates this lock can be safely eliminated |
783 bool _eliminate; // indicates this lock can be safely eliminated |
|
784 bool _coarsened; // indicates this lock was coarsened |
784 #ifndef PRODUCT |
785 #ifndef PRODUCT |
785 NamedCounter* _counter; |
786 NamedCounter* _counter; |
786 #endif |
787 #endif |
787 |
788 |
788 protected: |
789 protected: |
816 virtual uint size_of() const { return sizeof(*this); } |
818 virtual uint size_of() const { return sizeof(*this); } |
817 |
819 |
818 bool is_eliminated() {return _eliminate; } |
820 bool is_eliminated() {return _eliminate; } |
819 // mark node as eliminated and update the counter if there is one |
821 // mark node as eliminated and update the counter if there is one |
820 void set_eliminated(); |
822 void set_eliminated(); |
|
823 |
|
824 bool is_coarsened() { return _coarsened; } |
|
825 void set_coarsened() { _coarsened = true; } |
821 |
826 |
822 // locking does not modify its arguments |
827 // locking does not modify its arguments |
823 virtual bool may_modify(const TypePtr *addr_t, PhaseTransform *phase){ return false;} |
828 virtual bool may_modify(const TypePtr *addr_t, PhaseTransform *phase){ return false;} |
824 |
829 |
825 #ifndef PRODUCT |
830 #ifndef PRODUCT |