test/compiler/compilercontrol/TestCompilerDirectivesCompatibilityCommandOff.java
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File
*** old/test/compiler/compilercontrol/TestCompilerDirectivesCompatibilityCommandOff.java Tue Feb 16 13:45:49 2016
--- new/test/compiler/compilercontrol/TestCompilerDirectivesCompatibilityCommandOff.java Tue Feb 16 13:45:49 2016
*** 27,41 ****
--- 27,41 ----
* @library /testlibrary /test/lib
* @modules java.base/sun.misc
* java.compiler
* java.management
* @build jdk.test.lib.*
! * @build jdk.test.lib.dcmd.*
! * @build sun.hotspot.WhiteBox
! * @run main ClassFileInstaller sun.hotspot.WhiteBox
! * jdk.test.lib.dcmd.*
! * sun.hotspot.WhiteBox
! * @run driver ClassFileInstaller sun.hotspot.WhiteBox
* sun.hotspot.WhiteBox$WhiteBoxPermission
! * @run testng/othervm -Xbootclasspath/a:. -Xmixed -XX:+UnlockDiagnosticVMOptions
* -XX:-PrintAssembly -XX:CompileCommand=option,*.helper,bool,PrintAssembly,false
* -XX:+WhiteBoxAPI TestCompilerDirectivesCompatibilityCommandOff
* @summary Test compiler control compatibility with compile command
*/
*** 53,81 ****
--- 53,81 ----
import java.lang.reflect.Method;
import java.util.Objects;
public class TestCompilerDirectivesCompatibilityCommandOff extends TestCompilerDirectivesCompatibilityBase {
! public void testCompatibility(CommandExecutor executor, int comp_level) throws Exception {
// Call all validation twice to catch error when overwriting a directive
// Flag is default off
! expect(!WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
! expect(!WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
// load directives that turn it on
executor.execute("Compiler.directives_add " + control_on);
! expect(WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
! expect(WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
// remove and see that it is false again
executor.execute("Compiler.directives_remove");
! expect(!WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
! expect(!WB.shouldPrintAssembly(method, comp_level));
! expect(!WB.shouldPrintAssembly(nomatch, comp_level));
}
}
test/compiler/compilercontrol/TestCompilerDirectivesCompatibilityCommandOff.java
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File