1.1 --- a/src/share/vm/runtime/synchronizer.hpp Mon Jun 28 12:03:05 2010 -0400 1.2 +++ b/src/share/vm/runtime/synchronizer.hpp Fri Jul 02 17:23:43 2010 -0400 1.3 @@ -122,8 +122,9 @@ 1.4 static void reenter (Handle obj, intptr_t recursion, TRAPS); 1.5 1.6 // thread-specific and global objectMonitor free list accessors 1.7 +// static void verifyInUse (Thread * Self) ; too slow for general assert/debug 1.8 static ObjectMonitor * omAlloc (Thread * Self) ; 1.9 - static void omRelease (Thread * Self, ObjectMonitor * m) ; 1.10 + static void omRelease (Thread * Self, ObjectMonitor * m, bool FromPerThreadAlloc) ; 1.11 static void omFlush (Thread * Self) ; 1.12 1.13 // Inflate light weight monitor to heavy weight monitor 1.14 @@ -150,6 +151,9 @@ 1.15 // Basically we deflate all monitors that are not busy. 1.16 // An adaptive profile-based deflation policy could be used if needed 1.17 static void deflate_idle_monitors(); 1.18 + static int walk_monitor_list(ObjectMonitor** listheadp, 1.19 + ObjectMonitor** FreeHeadp, 1.20 + ObjectMonitor** FreeTailp); 1.21 static bool deflate_monitor(ObjectMonitor* mid, oop obj, ObjectMonitor** FreeHeadp, 1.22 ObjectMonitor** FreeTailp); 1.23 static void oops_do(OopClosure* f); 1.24 @@ -163,6 +167,8 @@ 1.25 enum { _BLOCKSIZE = 128 }; 1.26 static ObjectMonitor* gBlockList; 1.27 static ObjectMonitor * volatile gFreeList; 1.28 + static ObjectMonitor * volatile gOmInUseList; // for moribund thread, so monitors they inflated still get scanned 1.29 + static int gOmInUseCount; 1.30 1.31 public: 1.32 static void Initialize () ;