src/share/vm/opto/locknode.cpp

changeset 6429
606acabe7b5c
parent 4313
beebba0acc11
child 6876
710a3c8b516e
     1.1 --- a/src/share/vm/opto/locknode.cpp	Sat Mar 22 00:26:48 2014 +0400
     1.2 +++ b/src/share/vm/opto/locknode.cpp	Thu Mar 20 17:49:27 2014 -0700
     1.3 @@ -136,6 +136,8 @@
     1.4  //-----------------------------hash--------------------------------------------
     1.5  uint FastLockNode::hash() const { return NO_HASH; }
     1.6  
     1.7 +uint FastLockNode::size_of() const { return sizeof(*this); }
     1.8 +
     1.9  //------------------------------cmp--------------------------------------------
    1.10  uint FastLockNode::cmp( const Node &n ) const {
    1.11    return (&n == this);                // Always fail except on self
    1.12 @@ -159,6 +161,22 @@
    1.13    _counters = blnc->counters();
    1.14  }
    1.15  
    1.16 +void FastLockNode::create_rtm_lock_counter(JVMState* state) {
    1.17 +#if INCLUDE_RTM_OPT
    1.18 +  Compile* C = Compile::current();
    1.19 +  if (C->profile_rtm() || (PrintPreciseRTMLockingStatistics && C->use_rtm())) {
    1.20 +    RTMLockingNamedCounter* rlnc = (RTMLockingNamedCounter*)
    1.21 +           OptoRuntime::new_named_counter(state, NamedCounter::RTMLockingCounter);
    1.22 +    _rtm_counters = rlnc->counters();
    1.23 +    if (UseRTMForStackLocks) {
    1.24 +      rlnc = (RTMLockingNamedCounter*)
    1.25 +           OptoRuntime::new_named_counter(state, NamedCounter::RTMLockingCounter);
    1.26 +      _stack_rtm_counters = rlnc->counters();
    1.27 +    }
    1.28 +  }
    1.29 +#endif
    1.30 +}
    1.31 +
    1.32  //=============================================================================
    1.33  //------------------------------do_monitor_enter-------------------------------
    1.34  void Parse::do_monitor_enter() {

mercurial