< prev index next >

src/hotspot/share/runtime/objectMonitor.hpp

Print this page
rev 59856 : 8247280: more fencing needed in async deflation for non-TSO machines
Reviewed-by: dholmes


 313     // _cxq == 0 _succ == NULL _owner == NULL _waiters == 0
 314     // _contentions == 0 EntryList  == NULL
 315     // _recursions == 0 _WaitSet == NULL
 316 #ifdef ASSERT
 317     stringStream ss;
 318 #endif
 319     assert((is_busy() | _recursions) == 0, "freeing in-use monitor: %s, "
 320            "recursions=" INTX_FORMAT, is_busy_to_string(&ss), _recursions);
 321     _succ          = NULL;
 322     _EntryList     = NULL;
 323     _cxq           = NULL;
 324     _WaitSet       = NULL;
 325     _recursions    = 0;
 326   }
 327 
 328  public:
 329 
 330   void*     object() const;
 331   void*     object_addr();
 332   void      set_object(void* obj);

 333   void      set_allocation_state(AllocationState s);
 334   AllocationState allocation_state() const;

 335   bool      is_free() const;
 336   bool      is_old() const;
 337   bool      is_new() const;
 338 
 339   // Returns true if the specified thread owns the ObjectMonitor. Otherwise
 340   // returns false and throws IllegalMonitorStateException (IMSE).
 341   bool      check_owner(Thread* THREAD);
 342   void      clear();
 343   void      clear_common();
 344 
 345   bool      enter(TRAPS);
 346   void      exit(bool not_suspended, TRAPS);
 347   void      wait(jlong millis, bool interruptable, TRAPS);
 348   void      notify(TRAPS);
 349   void      notifyAll(TRAPS);
 350 
 351   void      print() const;
 352 #ifdef ASSERT
 353   void      print_debug_style_on(outputStream* st) const;
 354 #endif




 313     // _cxq == 0 _succ == NULL _owner == NULL _waiters == 0
 314     // _contentions == 0 EntryList  == NULL
 315     // _recursions == 0 _WaitSet == NULL
 316 #ifdef ASSERT
 317     stringStream ss;
 318 #endif
 319     assert((is_busy() | _recursions) == 0, "freeing in-use monitor: %s, "
 320            "recursions=" INTX_FORMAT, is_busy_to_string(&ss), _recursions);
 321     _succ          = NULL;
 322     _EntryList     = NULL;
 323     _cxq           = NULL;
 324     _WaitSet       = NULL;
 325     _recursions    = 0;
 326   }
 327 
 328  public:
 329 
 330   void*     object() const;
 331   void*     object_addr();
 332   void      set_object(void* obj);
 333   void      release_set_allocation_state(AllocationState s);
 334   void      set_allocation_state(AllocationState s);
 335   AllocationState allocation_state() const;
 336   AllocationState allocation_state_acquire() const;
 337   bool      is_free() const;
 338   bool      is_old() const;
 339   bool      is_new() const;
 340 
 341   // Returns true if the specified thread owns the ObjectMonitor. Otherwise
 342   // returns false and throws IllegalMonitorStateException (IMSE).
 343   bool      check_owner(Thread* THREAD);
 344   void      clear();
 345   void      clear_common();
 346 
 347   bool      enter(TRAPS);
 348   void      exit(bool not_suspended, TRAPS);
 349   void      wait(jlong millis, bool interruptable, TRAPS);
 350   void      notify(TRAPS);
 351   void      notifyAll(TRAPS);
 352 
 353   void      print() const;
 354 #ifdef ASSERT
 355   void      print_debug_style_on(outputStream* st) const;
 356 #endif


< prev index next >