提交 4e336f54 编写于 作者: A aph

6888526: Linux getCurrentThreadCpuTime is drastically slower than Windows

Reviewed-by: dcubed, dholmes
上级 b5a6f4ac
......@@ -29,9 +29,10 @@
product(bool, UseOprofile, false, \
"enable support for Oprofile profiler") \
\
product(bool, UseLinuxPosixThreadCPUClocks, false, \
"enable fast Linux Posix clocks where available") \
product(bool, UseLinuxPosixThreadCPUClocks, true, \
"enable fast Linux Posix clocks where available")
// NB: The default value of UseLinuxPosixThreadCPUClocks may be
// overridden in Arguments::parse_each_vm_init_arg.
//
// Defines Linux-specific default values. The flags are available on all
......
......@@ -2593,6 +2593,12 @@ SOLARIS_ONLY(
FLAG_IS_DEFAULT(UseVMInterruptibleIO)) {
FLAG_SET_DEFAULT(UseVMInterruptibleIO, true);
}
#ifdef LINUX
if (JDK_Version::current().compare_major(6) <= 0 &&
FLAG_IS_DEFAULT(UseLinuxPosixThreadCPUClocks)) {
FLAG_SET_DEFAULT(UseLinuxPosixThreadCPUClocks, false);
}
#endif // LINUX
return JNI_OK;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册