comparison src/share/vm/runtime/thread.cpp @ 1688:2dfd013a7465

6975078: assert(allocated_on_res_area() || allocated_on_C_heap() || allocated_on_arena() Summary: Pass the check in ResourceObj() if _allocation value is already set and object is allocated on stack. Reviewed-by: dholmes, johnc
author kvn
date Mon, 09 Aug 2010 15:17:05 -0700
parents 2389669474a6
children f4f596978298
comparison
equal deleted inserted replaced
1687:fb8abd207dbe 1688:2dfd013a7465
805 // However, there is a note in JavaThread::is_lock_owned() about the VM threads not being 805 // However, there is a note in JavaThread::is_lock_owned() about the VM threads not being
806 // used for compilation in the future. If that change is made, the need for these methods 806 // used for compilation in the future. If that change is made, the need for these methods
807 // should be revisited, and they should be removed if possible. 807 // should be revisited, and they should be removed if possible.
808 808
809 bool Thread::is_lock_owned(address adr) const { 809 bool Thread::is_lock_owned(address adr) const {
810 return (_stack_base >= adr && adr >= (_stack_base - _stack_size)); 810 return on_local_stack(adr);
811 } 811 }
812 812
813 bool Thread::set_as_starting_thread() { 813 bool Thread::set_as_starting_thread() {
814 // NOTE: this must be called inside the main thread. 814 // NOTE: this must be called inside the main thread.
815 return os::create_main_thread((JavaThread*)this); 815 return os::create_main_thread((JavaThread*)this);