United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6629887 64-bit windows should not restrict default heap size to 1400m
JDK-6629887 : 64-bit windows should not restrict default heap size to 1400m

Details
Type:
Bug
Submit Date:
2007-11-14
Status:
Closed
Updated Date:
2012-10-08
Project Name:
JDK
Resolved Date:
2008-04-18
Component:
hotspot
OS:
windows
Sub-Component:
runtime
CPU:
x86
Priority:
P3
Resolution:
Fixed
Affected Versions:
7
Fixed Versions:
hs11 (b09)

Related Reports
Backport:
Backport:

Sub Tasks

Description
The default heap size on Windows, both 32 and 64-bit, is 1400mb.  This makes
sense on 32-bit Windows due to the address space break at 2gb, but doesn't
on 64-bit Windows.  We should remove the restriction for 64-bit platforms.

                                    

Comments
EVALUATION

There's #ifdef'ed AMD64 code in src/os_cpu/linux_x86/vm/os_linux_x86.cpp that should
probably by #ifdef'ed _LP64.  If it were, we could move allocatable_physical_memory
back to os_linux.cpp.
                                     
2007-11-14
SUGGESTED FIX

In src/os/windows/vm/os_windows.cpp, replace

julong os::allocatable_physical_memory(julong size) {
  return MIN2(size, (julong)1400*M);
}

with

julong os::allocatable_physical_memory(julong size) {
#ifdef _LP64
  return size;
#else
  return MIN2(size, (julong)1400*M);
#endif
}
                                     
2007-11-14



Hardware and Software, Engineered to Work Together