--- a/hotspot/src/share/vm/utilities/debug.cpp Fri Dec 04 04:29:31 2015 +0000
+++ b/hotspot/src/share/vm/utilities/debug.cpp Fri Dec 04 04:06:37 2015 -0500
@@ -215,7 +215,7 @@
if (Debugging || error_is_suppressed(file, line)) return;
va_list detail_args;
va_start(detail_args, detail_fmt);
- VMError::report_and_die(ThreadLocalStorage::get_thread_slow(), file, line, error_msg, detail_fmt, detail_args);
+ VMError::report_and_die(Thread::current_or_null(), file, line, error_msg, detail_fmt, detail_args);
va_end(detail_args);
}
@@ -224,7 +224,7 @@
if (Debugging || error_is_suppressed(file, line)) return;
va_list detail_args;
va_start(detail_args, detail_fmt);
- VMError::report_and_die(ThreadLocalStorage::get_thread_slow(), file, line, "fatal error", detail_fmt, detail_args);
+ VMError::report_and_die(Thread::current_or_null(), file, line, "fatal error", detail_fmt, detail_args);
va_end(detail_args);
}
@@ -233,7 +233,7 @@
if (Debugging) return;
va_list detail_args;
va_start(detail_args, detail_fmt);
- VMError::report_and_die(ThreadLocalStorage::get_thread_slow(), file, line, size, vm_err_type, detail_fmt, detail_args);
+ VMError::report_and_die(Thread::current_or_null(), file, line, size, vm_err_type, detail_fmt, detail_args);
va_end(detail_args);
// The UseOSErrorReporting option in report_and_die() may allow a return
@@ -536,7 +536,7 @@
#endif // !PRODUCT
extern "C" void ps() { // print stack
- if (Thread::current() == NULL) return;
+ if (Thread::current_or_null() == NULL) return;
Command c("ps");
@@ -615,7 +615,7 @@
#endif // !PRODUCT
extern "C" void pss() { // print all stacks
- if (Thread::current() == NULL) return;
+ if (Thread::current_or_null() == NULL) return;
Command c("pss");
Threads::print(true, PRODUCT_ONLY(false) NOT_PRODUCT(true));
}
@@ -772,7 +772,7 @@
extern "C" void pns(void* sp, void* fp, void* pc) { // print native stack
Command c("pns");
static char buf[O_BUFLEN];
- Thread* t = ThreadLocalStorage::get_thread_slow();
+ Thread* t = Thread::current_or_null();
// Call generic frame constructor (certain arguments may be ignored)
frame fr(sp, fp, pc);
print_native_stack(tty, fr, t, buf, sizeof(buf));