8166002: Emulate client build on platforms with reduced virtual address space

The default VM ergonomics on Windows/x86 (32-bit) are changed to client like.

Reviewed-by: kvn, iveresov
This commit is contained in:
Jamsheed Mohammed C M 2017-01-17 21:39:22 -08:00
parent 3e1eafa1d1
commit 0ac0d9ac29
2 changed files with 16 additions and 0 deletions

View File

@ -64,6 +64,7 @@ public class VMProps implements Callable<Map<String, String>> {
map.put("vm.simpleArch", vmArch());
map.put("vm.debug", vmDebug());
map.put("vm.jvmci", vmJvmci());
map.put("vm.emulatedClient", vmEmulatedClient());
map.put("vm.cpu.features", cpuFeatures());
vmGC(map); // vm.gc.X = true/false
@ -168,6 +169,17 @@ public class VMProps implements Callable<Map<String, String>> {
return "" + (WB.getBooleanVMFlag("EnableJVMCI") != null);
}
/**
* @return true if VM runs in emulated-client mode and false otherwise.
*/
protected String vmEmulatedClient() {
String vmInfo = System.getProperty("java.vm.info");
if (vmInfo == null) {
return "false";
}
return "" + vmInfo.contains(" emulated-client");
}
/**
* @return supported CPU features
*/

View File

@ -63,6 +63,10 @@ public class Platform {
return vmName.contains("Embedded");
}
public static boolean isEmulatedClient() {
return vmInfo.contains(" emulated-client");
}
public static boolean isTieredSupported() {
return compiler.contains("Tiered Compilers");
}