Java Code Examples for jdk.test.lib.Platform#isGraal()

The following examples show how to use jdk.test.lib.Platform#isGraal() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: CommandLineOptionTest.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * @return option required to start a new VM with the same type as current.
 * @throws RuntimeException when VM type is unknown.
 */
private static String getVMTypeOption() {
    if (Platform.isServer()) {
        return "-server";
    } else if (Platform.isClient()) {
        return "-client";
    } else if (Platform.isMinimal()) {
        return "-minimal";
    } else if (Platform.isGraal()) {
        return "-graal";
    }
    throw new RuntimeException("Unknown VM mode.");
}
 
Example 2
Source File: CommandLineOptionTest.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/**
 * @return option required to start a new VM with the same type as current.
 * @throws RuntimeException when VM type is unknown.
 */
private static String getVMTypeOption() {
    if (Platform.isServer()) {
        return "-server";
    } else if (Platform.isClient()) {
        return "-client";
    } else if (Platform.isMinimal()) {
        return "-minimal";
    } else if (Platform.isGraal()) {
        return "-graal";
    }
    throw new RuntimeException("Unknown VM mode.");
}
 
Example 3
Source File: CommandLineOptionTest.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * @return option required to start a new VM with the same type as current.
 * @throws RuntimeException when VM type is unknown.
 */
private static String getVMTypeOption() {
    if (Platform.isServer()) {
        return "-server";
    } else if (Platform.isClient()) {
        return "-client";
    } else if (Platform.isMinimal()) {
        return "-minimal";
    } else if (Platform.isGraal()) {
        return "-graal";
    }
    throw new RuntimeException("Unknown VM mode.");
}