Eclipse.ini配置超过1024MB
当我将 -Xmx2048m 设置为最大内存分配时,出现 JVM.termerated.exit code -1 错误。
我们如何在eclipse.ini中设置-Xmx2048m。我的应用程序在 -Xmx1024m 配置中抛出内存不足错误。所以我应该增加内存大小。我附上了 eclipse 错误日志和 eclipse.ini。
I got this JVM.terminated.exit code -1 error while I am setting -Xmx2048m as maximum memory allocation.
How can we set -Xmx2048m in eclipse.ini. My application throws out of memory error in -Xmx1024m configuration. So I should increase the memory size. I attached eclipse error log and eclipse.ini.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您在 Windows 32 位下运行,则限制约为 -Xmx1500m 到 -Xmx1800m,因为 Windows 32 位进程的地址空间略低于 2GB,其次 -Xmx 指定 Java 可用的堆内存量,但是 java 进程需要更多内存(用于 VM 本身和 PermGen)。由于 Java 需要(/d?)连续的虚拟内存区域,因此它可以占用的确切内存量还取决于其他进程已经加载的内容。
If you are running under Windows 32 bits, the limit is around -Xmx1500m to -Xmx1800m as Windows 32 bit processes have an address space of slightly below 2GB, secondly -Xmx specifies the amount of heap memory available to Java, the java process however requires more memory (for the VM itself, and for the PermGen). As Java requires(/d?) a contiguous virtual memory area, the exact amount of memory it can claim also depends on what other processes have already loaded.
您没有粘贴错误日志。该错误很可能是因为 2G 内存不可用。您可能想尝试较小的值。
You did not paste the error log. The error is most likely because 2G memory is not available. You might want to try a smaller value.