--- old/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java 2017-03-20 17:38:29.000000000 -0700 +++ new/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java 2017-03-20 17:38:29.000000000 -0700 @@ -24,7 +24,7 @@ import org.graalvm.compiler.options.Option; import org.graalvm.compiler.options.OptionType; -import org.graalvm.compiler.options.OptionValue; +import org.graalvm.compiler.options.OptionKey; /** * Options related to {@link CompileTheWorld}. @@ -35,40 +35,27 @@ public class CompileTheWorldOptions { // @formatter:off @Option(help = "Class path denoting methods to compile", type = OptionType.Debug) - public static final OptionValue CompileTheWorldClasspath = new OptionValue<>(CompileTheWorld.SUN_BOOT_CLASS_PATH); + public static final OptionKey CompileTheWorldClasspath = new OptionKey<>(CompileTheWorld.SUN_BOOT_CLASS_PATH); @Option(help = "Verbose CompileTheWorld operation", type = OptionType.Debug) - public static final OptionValue CompileTheWorldVerbose = new OptionValue<>(true); + public static final OptionKey CompileTheWorldVerbose = new OptionKey<>(true); @Option(help = "The number of CompileTheWorld iterations to perform", type = OptionType.Debug) - public static final OptionValue CompileTheWorldIterations = new OptionValue<>(1); + public static final OptionKey CompileTheWorldIterations = new OptionKey<>(1); @Option(help = "Only compile methods matching this filter", type = OptionType.Debug) - public static final OptionValue CompileTheWorldMethodFilter = new OptionValue<>(null); + public static final OptionKey CompileTheWorldMethodFilter = new OptionKey<>(null); @Option(help = "Exclude methods matching this filter from compilation", type = OptionType.Debug) - public static final OptionValue CompileTheWorldExcludeMethodFilter = new OptionValue<>(null); + public static final OptionKey CompileTheWorldExcludeMethodFilter = new OptionKey<>(null); @Option(help = "First class to consider when using -XX:+CompileTheWorld", type = OptionType.Debug) - public static final OptionValue CompileTheWorldStartAt = new OptionValue<>(1); + public static final OptionKey CompileTheWorldStartAt = new OptionKey<>(1); @Option(help = "Last class to consider when using -XX:+CompileTheWorld", type = OptionType.Debug) - public static final OptionValue CompileTheWorldStopAt = new OptionValue<>(Integer.MAX_VALUE); + public static final OptionKey CompileTheWorldStopAt = new OptionKey<>(Integer.MAX_VALUE); @Option(help = "Option value overrides to use during compile the world. For example, " + "to disable inlining and partial escape analysis specify 'PartialEscapeAnalysis=false Inline=false'. " + "The format for each option is the same as on the command line just without the '-Dgraal.' prefix.", type = OptionType.Debug) - public static final OptionValue CompileTheWorldConfig = new OptionValue<>(null); + public static final OptionKey CompileTheWorldConfig = new OptionKey<>(null); @Option(help = "Run CTW using as many threads as there are processors on the system", type = OptionType.Debug) - public static final OptionValue CompileTheWorldMultiThreaded = new OptionValue<>(false); + public static final OptionKey CompileTheWorldMultiThreaded = new OptionKey<>(false); @Option(help = "Number of threads to use for multithreaded CTW. Defaults to Runtime.getRuntime().availableProcessors()", type = OptionType.Debug) - public static final OptionValue CompileTheWorldThreads = new OptionValue<>(0); + public static final OptionKey CompileTheWorldThreads = new OptionKey<>(0); // @formatter:on - - /** - * Overrides {@link #CompileTheWorldStartAt} and {@link #CompileTheWorldStopAt} from {@code -XX} - * HotSpot options of the same name if the latter have non-default values. - */ - public static void overrideWithNativeOptions(GraalHotSpotVMConfig c) { - if (c.compileTheWorldStartAt != 1) { - CompileTheWorldStartAt.setValue(c.compileTheWorldStartAt); - } - if (c.compileTheWorldStopAt != Integer.MAX_VALUE) { - CompileTheWorldStopAt.setValue(c.compileTheWorldStopAt); - } - } }