Mercurial > hg > truffle
comparison test/compiler/rtm/cli/TestUseRTMLockingOptionOnSupportedConfig.java @ 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 | cabe05c85665 |
children |
comparison
equal
deleted
inserted
replaced
20373:c67b85c32d9a | 20374:999824269b71 |
---|---|
56 // verify that there are no warning or error in VM output | 56 // verify that there are no warning or error in VM output |
57 CommandLineOptionTest.verifySameJVMStartup(null, | 57 CommandLineOptionTest.verifySameJVMStartup(null, |
58 new String[]{ | 58 new String[]{ |
59 RTMGenericCommandLineOptionTest.RTM_INSTR_ERROR, | 59 RTMGenericCommandLineOptionTest.RTM_INSTR_ERROR, |
60 unrecongnizedOption | 60 unrecongnizedOption |
61 }, ExitCode.OK, "-XX:+UseRTMLocking" | 61 }, ExitCode.OK, |
62 CommandLineOptionTest.UNLOCK_EXPERIMENTAL_VM_OPTIONS, | |
63 "-XX:+UseRTMLocking" | |
62 ); | 64 ); |
63 | 65 |
64 CommandLineOptionTest.verifySameJVMStartup(null, | 66 CommandLineOptionTest.verifySameJVMStartup(null, |
65 new String[]{ | 67 new String[]{ |
66 RTMGenericCommandLineOptionTest.RTM_INSTR_ERROR, | 68 RTMGenericCommandLineOptionTest.RTM_INSTR_ERROR, |
67 unrecongnizedOption | 69 unrecongnizedOption |
68 }, ExitCode.OK, "-XX:-UseRTMLocking" | 70 }, ExitCode.OK, |
71 CommandLineOptionTest.UNLOCK_EXPERIMENTAL_VM_OPTIONS, | |
72 "-XX:-UseRTMLocking" | |
69 ); | 73 ); |
70 // verify that UseRTMLocking is of by default | 74 // verify that UseRTMLocking is of by default |
71 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", | 75 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", |
72 TestUseRTMLockingOptionOnSupportedConfig.DEFAULT_VALUE); | 76 TestUseRTMLockingOptionOnSupportedConfig.DEFAULT_VALUE, |
77 CommandLineOptionTest.UNLOCK_EXPERIMENTAL_VM_OPTIONS); | |
73 // verify that we can change UseRTMLocking value | 78 // verify that we can change UseRTMLocking value |
74 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", | 79 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", |
75 TestUseRTMLockingOptionOnSupportedConfig.DEFAULT_VALUE, | 80 TestUseRTMLockingOptionOnSupportedConfig.DEFAULT_VALUE, |
81 CommandLineOptionTest.UNLOCK_EXPERIMENTAL_VM_OPTIONS, | |
76 "-XX:-UseRTMLocking"); | 82 "-XX:-UseRTMLocking"); |
77 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", | 83 CommandLineOptionTest.verifyOptionValueForSameVM("UseRTMLocking", |
78 "true", "-XX:+UseRTMLocking"); | 84 "true", CommandLineOptionTest.UNLOCK_EXPERIMENTAL_VM_OPTIONS, |
85 "-XX:+UseRTMLocking"); | |
79 } | 86 } |
80 | 87 |
81 public static void main(String args[]) throws Throwable { | 88 public static void main(String args[]) throws Throwable { |
82 new TestUseRTMLockingOptionOnSupportedConfig().test(); | 89 new TestUseRTMLockingOptionOnSupportedConfig().test(); |
83 } | 90 } |