8231413: Several test/hotspot/jtreg/runtime tests updates to run with --illegal-access=deny

Reviewed-by: hseigel, lfoltan, dholmes
This commit is contained in:
Alan Bateman 2019-09-25 09:17:32 +01:00
parent dfc5c795c7
commit 72e62cf835
6 changed files with 8 additions and 2 deletions

View File

@ -49,8 +49,9 @@ public class invocationC1Tests {
System.out.println("\nC1 invocation tests, Tests: " + whichTests +
", class file version: " + classFileVersion);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(false, "-Xmx128M",
"-Xcomp", "-XX:TieredStopAtLevel=1", whichTests,
"--classfile_version=" + classFileVersion);
"-Xcomp", "-XX:TieredStopAtLevel=1",
"--add-exports", "java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED",
whichTests, "--classfile_version=" + classFileVersion);
OutputAnalyzer output = new OutputAnalyzer(pb.start());
try {
output.shouldContain("EXECUTION STATUS: PASSED");

View File

@ -51,6 +51,7 @@ public class invocationGraalTests {
", class file version: " + classFileVersion);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(false, "-Xmx128M",
"-XX:+UnlockExperimentalVMOptions", "-XX:+EnableJVMCI", "-XX:+UseJVMCICompiler",
"--add-exports", "java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED",
whichTests, "--classfile_version=" + classFileVersion);
OutputAnalyzer output = new OutputAnalyzer(pb.start());
try {

View File

@ -48,6 +48,7 @@ public class invokeinterfaceTests {
System.out.println("\ninvokeinterface invocation tests, option: " + option +
", class file version: " + classFileVersion);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(false, "-Xmx128M", option,
"--add-exports", "java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED",
"invokeinterface.Generator", "--classfile_version=" + classFileVersion);
OutputAnalyzer output = new OutputAnalyzer(pb.start());
try {

View File

@ -47,6 +47,7 @@ public class invokespecialTests {
System.out.println("\ninvokespecial invocation tests, option: " + option +
", class file version: " + classFileVersion);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(false, "-Xmx128M", option,
"--add-exports", "java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED",
"invokespecial.Generator", "--classfile_version=" + classFileVersion);
OutputAnalyzer output = new OutputAnalyzer(pb.start());
try {

View File

@ -47,6 +47,7 @@ public class invokevirtualTests {
System.out.println("\ninvokevirtual invocation tests, option: " + option +
", class file version: " + classFileVersion);
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(false, "-Xmx128M", option,
"--add-exports", "java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED",
"invokevirtual.Generator", "--classfile_version=" + classFileVersion);
OutputAnalyzer output = new OutputAnalyzer(pb.start());
try {

View File

@ -28,6 +28,7 @@
* @summary Check that SIGBUS errors caused by memory accesses in Unsafe_CopyMemory()
* and UnsafeCopySwapMemory() get converted to java.lang.InternalError exceptions.
* @modules java.base/jdk.internal.misc
* java.base/java.nio:+open
*
* @library /test/lib
* @build sun.hotspot.WhiteBox