mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 14:24:46 +02:00
6629887: 64-bit windows should not restrict default heap size to 1400m
Reviewed-by: jmasa, sbohne, ikrylov, xlu
This commit is contained in:
parent
b3b837074b
commit
4576d7abf7
3 changed files with 19 additions and 15 deletions
|
@ -116,6 +116,20 @@ julong os::physical_memory() {
|
|||
return Linux::physical_memory();
|
||||
}
|
||||
|
||||
julong os::allocatable_physical_memory(julong size) {
|
||||
#ifdef _LP64
|
||||
return size;
|
||||
#else
|
||||
julong result = MIN2(size, (julong)3800*M);
|
||||
if (!is_allocatable(result)) {
|
||||
// See comments under solaris for alignment considerations
|
||||
julong reasonable_size = (julong)2*G - 2 * os::vm_page_size();
|
||||
result = MIN2(size, reasonable_size);
|
||||
}
|
||||
return result;
|
||||
#endif // _LP64
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// environment support
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue