Mercurial > hg > truffle
diff src/cpu/x86/vm/vm_version_x86.cpp @ 20374:999824269b71
8055069: TSX and RTM should be deprecated more strongly until hardware is corrected
Summary: Require to specify UnlockExperimentalVMOptions flag together with UseRTMLocking flag on un-patched systems where CPUID allows it but is unsupported otherwise.
Reviewed-by: iveresov, fzhinkin
author | kvn |
---|---|
date | Fri, 22 Aug 2014 12:03:49 -0700 |
parents | b20a35eae442 |
children | 166d744df0de |
line wrap: on
line diff
--- a/src/cpu/x86/vm/vm_version_x86.cpp Thu Aug 28 14:05:08 2014 -0700 +++ b/src/cpu/x86/vm/vm_version_x86.cpp Fri Aug 22 12:03:49 2014 -0700 @@ -612,6 +612,17 @@ #if INCLUDE_RTM_OPT if (UseRTMLocking) { + if (is_intel_family_core()) { + if ((_model == CPU_MODEL_HASWELL_E3) || + (_model == CPU_MODEL_HASWELL_E7 && _stepping < 3) || + (_model == CPU_MODEL_BROADWELL && _stepping < 4)) { + if (!UnlockExperimentalVMOptions) { + vm_exit_during_initialization("UseRTMLocking is only available as experimental option on this platform. It must be enabled via -XX:+UnlockExperimentalVMOptions flag."); + } else { + warning("UseRTMLocking is only available as experimental option on this platform."); + } + } + } if (!FLAG_IS_CMDLINE(UseRTMLocking)) { // RTM locking should be used only for applications with // high lock contention. For now we do not use it by default.