2 回答

TA貢獻1841條經驗 獲得超3個贊
Oracle 官方文檔:
The maximum theoretical heap limit for the 32-bit JVM is 4G. Due to various additional constraints such as available swap, kernel address space usage, memory fragmentation, and VM overhead, in practice the limit can be much lower. On most modern 32-bit Windows systems the maximum heap size will range from 1.4G to 1.6G. On 32-bit Solaris kernels the address space is limited to 2G. On 64-bit operating systems running the 32-bit VM, the max heap size can be higher, approaching 4G on many Solaris systems.
幫你翻譯一下吧:
理論上,32位的Java虛擬機的Heap(堆)的上限是4G,然而由于其他各種限制,比如可用的交換區,內核地址空間使用,內存碎片和VM overhead(JVM的開銷?棧?)等,實際上這個上限可能遠小于理論值。在大多數32位的Windows系統上,實際值從1.4G到1.6G不等。在32位的Solaris內核中,地址空間限定到2G。在64位操作系統上運行32位Java虛擬機,該值可能要高一些,比如在很多Solaris系統上就接近4G。
添加回答
舉報