我怎样才能给 eclipse 超过 512M 的内存? [英] How can I give eclipse more memory than 512M?

查看:23
本文介绍了我怎样才能给 eclipse 超过 512M 的内存?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有以下设置,但是当我放入 1024 并将所有 512 替换为 1024 时,eclipse 根本无法启动.我的eclipse JVM怎么能有超过512M的内存?

I have following setup, but when I put 1024 and replace all 512 with 1024, then eclipse won't start at all. How can I have more than 512M memory for my eclipse JVM?

-startup
plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519
-product
com.springsource.sts.ide
--launcher.XXMaxPermSize
512M
-vm
C:Program Files (x86)Javajdk1.6.0_18injavaw 
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms512m
-Xmx512m
-XX:MaxPermSize=512m

推荐答案

我在尝试让 Eclipse 接受尽可能多的内存(2 到 4例如演出).

I've had a lot of problems trying to get Eclipse to accept as much memory as I'd like it to be able to use (between 2 and 4 gigs for example).

打开Eclipse安装目录中的eclipse.ini.您应该能够在 -vmargs 到 1024 之后毫无问题地更改内存大小 到取决于您的系统的某个最大值.这是我的 Linux 机器上的那部分:

Open eclipse.ini in the Eclipse installation directory. You should be able to change the memory sizes after -vmargs up to 1024 without a problem up to some maximum value that's dependent on your system. Here's that section on my Linux box:

-vmargs
-Dosgi.requiredJavaVersion=1.5
-XX:MaxPermSize=512m
-Xms512m
-Xmx1024m

这是我的 Windows 盒子上的那个部分:

And here's that section on my Windows box:

-vmargs
-Xms256m
-Xmx1024m

但是,我未能将其设置为高于 1024 megs.如果有人知道如何完成这项工作,我很想知道.

But, I've failed at setting it higher than 1024 megs. If anybody knows how to make that work, I'd love to know.

编辑:32 位版本的 juno 似乎不接受超过 Xmx1024m 的内容,而 64 位版本接受 2048.

EDIT: 32bit version of juno seems to not accept more than Xmx1024m where the 64 bit version accept 2048.

编辑:Nick 的帖子包含一些很好的链接,可以解释两种不同的情况:

EDIT: Nick's post contains some great links that explain two different things:

  • 问题很大程度上取决于您的系统和可用的连续空闲内存量,以及
  • 通过使用 javaw.exe(在 Windows 上),您可以获得更大的分配内存块.
  • The problem is largely dependent on your system and the amount of contiguous free memory available, and
  • By using javaw.exe (on Windows), you may be able to get a larger allocated block of memory.

我有 8 场内存,并且无法将 -Xmx 设置为超过 1024 兆内存,即使加载了最少量的程序并且 windows/linux 报告都在 4 到 5 之间免费 ram 的演出.

I have 8 gigs of Ram and can't set -Xmx to more than 1024 megs of ram, even when a minimal amount of programs are loaded and both windows/linux report between 4 and 5 gigs of free ram.

这篇关于我怎样才能给 eclipse 超过 512M 的内存?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆