src/share/vm/runtime/thread.cpp
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File
*** old/src/share/vm/runtime/thread.cpp Fri Sep 14 11:08:35 2012
--- new/src/share/vm/runtime/thread.cpp Fri Sep 14 11:08:34 2012
*** 326,337 ****
--- 326,343 ----
Thread::~Thread() {
// Reclaim the objectmonitors from the omFreeList of the moribund thread.
ObjectSynchronizer::omFlush (this) ;
+ // stack_base can be NULL if the thread is never started or exited before
+ // record_stack_base_and_size called. Although, we would like to ensure
+ // that all started threads do call record_stack_base_and_size(), there is
+ // not proper way to enforce that.
+ if (_stack_base != NULL) {
address low_stack_addr = stack_base() - stack_size();
MemTracker::release_thread_stack(low_stack_addr, stack_size(), this);
+ }
// deallocate data structures
delete resource_area();
// since the handle marks are using the handle area, we have to deallocated the root
// handle mark before deallocating the thread's handle area,
src/share/vm/runtime/thread.cpp
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File