--- old/test/hotspot/jtreg/runtime/appcds/sharedStrings/ExerciseGC.java 2018-10-30 10:15:50.193443922 -0700 +++ new/test/hotspot/jtreg/runtime/appcds/sharedStrings/ExerciseGC.java 2018-10-30 10:15:49.789428684 -0700 @@ -27,17 +27,16 @@ * @summary Exercise GC with shared strings * @requires vm.cds.archived.java.heap * @library /test/hotspot/jtreg/runtime/appcds /test/lib - * @modules java.base/jdk.internal.misc - * @modules java.management - * jdk.jartool/sun.tools.jar + * @modules jdk.jartool/sun.tools.jar * @build HelloStringGC sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * @run driver ExerciseGC - * @run main/othervm -XX:+UseStringDeduplication ExerciseGC - * @run main/othervm -XX:-CompactStrings ExerciseGC */ public class ExerciseGC { public static void main(String[] args) throws Exception { + SharedStringsUtils.run(args, ExerciseGC::test); + } + public static void test(String[] args) throws Exception { SharedStringsUtils.buildJarAndWhiteBox("HelloStringGC"); SharedStringsUtils.dumpWithWhiteBox(TestCommon.list("HelloStringGC"),