diff --git a/src/hotspot/share/code/stubs.cpp b/src/hotspot/share/code/stubs.cpp index 81717b9..d751f3d 100644 --- a/src/hotspot/share/code/stubs.cpp +++ b/src/hotspot/share/code/stubs.cpp @@ -117,7 +117,7 @@ Stub* StubQueue::request_committed(int code_size) { Stub* StubQueue::request(int requested_code_size) { assert(requested_code_size > 0, "requested_code_size must be > 0"); - if (_mutex != NULL) _mutex->lock(); + if (_mutex != NULL) _mutex->lock_without_safepoint_check(); Stub* s = current_stub(); int requested_size = align_up(stub_code_size_to_size(requested_code_size), CodeEntryAlignment); if (requested_size <= available_space()) { @@ -207,7 +207,7 @@ void StubQueue::remove_all(){ void StubQueue::verify() { // verify only if initialized if (_stub_buffer == NULL) return; - MutexLockerEx lock(_mutex); + MutexLockerEx lock(_mutex, Mutex::_no_safepoint_check_flag); // verify index boundaries guarantee(0 <= _buffer_size, "buffer size must be positive"); guarantee(0 <= _buffer_limit && _buffer_limit <= _buffer_size , "_buffer_limit out of bounds"); @@ -234,9 +234,8 @@ void StubQueue::verify() { void StubQueue::print() { - MutexLockerEx lock(_mutex); + MutexLockerEx lock(_mutex, Mutex::_no_safepoint_check_flag); for (Stub* s = first(); s != NULL; s = next(s)) { stub_print(s); } } -