--- a/hotspot/src/share/vm/runtime/thread.cpp Tue Mar 22 18:41:09 2016 -0700
+++ b/hotspot/src/share/vm/runtime/thread.cpp Wed Mar 23 23:36:29 2016 +0100
@@ -35,6 +35,7 @@
#include "compiler/compileTask.hpp"
#include "gc/shared/gcId.hpp"
#include "gc/shared/gcLocker.inline.hpp"
+#include "gc/shared/referencePendingListLocker.hpp"
#include "gc/shared/workgroup.hpp"
#include "interpreter/interpreter.hpp"
#include "interpreter/linkResolver.hpp"
@@ -68,7 +69,7 @@
#include "runtime/java.hpp"
#include "runtime/javaCalls.hpp"
#include "runtime/jniPeriodicChecker.hpp"
-#include "runtime/logTimer.hpp"
+#include "runtime/timerTrace.hpp"
#include "runtime/memprofiler.hpp"
#include "runtime/mutexLocker.hpp"
#include "runtime/objectMonitor.hpp"
@@ -3416,7 +3417,7 @@
}
void Threads::initialize_java_lang_classes(JavaThread* main_thread, TRAPS) {
- TraceStartupTime timer("Initialize java.lang classes");
+ TraceTime timer("Initialize java.lang classes", TRACETIME_LOG(Info, startuptime));
if (EagerXrunInit && Arguments::init_libraries_at_startup()) {
create_vm_init_libraries();
@@ -3468,7 +3469,7 @@
}
void Threads::initialize_jsr292_core_classes(TRAPS) {
- TraceStartupTime timer("Initialize java.lang.invoke classes");
+ TraceTime timer("Initialize java.lang.invoke classes", TRACETIME_LOG(Info, startuptime));
initialize_class(vmSymbols::java_lang_invoke_MethodHandle(), CHECK);
initialize_class(vmSymbols::java_lang_invoke_MemberName(), CHECK);
@@ -3539,7 +3540,7 @@
HOTSPOT_VM_INIT_BEGIN();
// Timing (must come after argument parsing)
- TraceStartupTime timer("Create VM");
+ TraceTime timer("Create VM", TRACETIME_LOG(Info, startuptime));
// Initialize the os module after parsing the args
jint os_init_2_result = os::init_2();
@@ -3628,7 +3629,7 @@
JvmtiExport::transition_pending_onload_raw_monitors();
// Create the VMThread
- { TraceStartupTime timer("Start VMThread");
+ { TraceTime timer("Start VMThread", TRACETIME_LOG(Info, startuptime));
VMThread::create();
Thread* vmthread = VMThread::vm_thread();
@@ -3703,18 +3704,9 @@
// set_init_completed has just been called, causing exceptions not to be shortcut
// anymore. We call vm_exit_during_initialization directly instead.
-#if INCLUDE_ALL_GCS
- // Support for ConcurrentMarkSweep. This should be cleaned up
- // and better encapsulated. The ugly nested if test would go away
- // once things are properly refactored. XXX YSR
- if (UseConcMarkSweepGC || UseG1GC) {
- if (UseConcMarkSweepGC) {
- ConcurrentMarkSweepThread::makeSurrogateLockerThread(CHECK_JNI_ERR);
- } else {
- ConcurrentMarkThread::makeSurrogateLockerThread(CHECK_JNI_ERR);
- }
- }
-#endif // INCLUDE_ALL_GCS
+ // Initialize reference pending list locker
+ bool needs_locker_thread = Universe::heap()->needs_reference_pending_list_locker_thread();
+ ReferencePendingListLocker::initialize(needs_locker_thread, CHECK_JNI_ERR);
// Signal Dispatcher needs to be started before VMInit event is posted
os::signal_init();