Android Eclipse 因 GC 开销限制超出错误而崩溃
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/23080078/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Eclipse crashes with a GC overhead limit exceeded error
提问by Silvio
It's the first time I am using Proguard, I've noticed that if you add many custom rules to proguard-project.txt
it takes obviously much more time for building. That's cause Eclipse to crash reporting a GC overhead limit exceeded
and then I have to force the shut down of java because the editor continues to pop out error and alert dialogs. Is there any way to avoid these continuous crashes on Eclipse and so fix the problem reported heretoo?
这是我第一次使用 Proguard,我注意到如果你添加许多自定义规则,proguard-project.txt
显然需要更多的时间来构建。这导致 Eclipse 崩溃报告 a GC overhead limit exceeded
,然后我必须强制关闭 java,因为编辑器继续弹出错误和警报对话框。有什么办法可以避免 Eclipse 上的这些连续崩溃,从而也解决这里报告的问题?
回答by Silvio
Fixed, I read all the others forum posts about the problem but no one said how to fix it on Eclipse. I found the fix here
已修复,我阅读了有关该问题的所有其他论坛帖子,但没有人说如何在 Eclipse 上修复它。我在这里找到了修复
EDIT: in case the link becomes dead, here's what you can do. Edit "eclipse.ini", and set something like that:
编辑:如果链接失效,您可以这样做。编辑“eclipse.ini”,并设置如下:
-XX:MaxPermSize=1024m
-Xms512m
-Xmx1024m
回答by AbuQauod
Remove all errors and warnings from your layouts. Make sure you are running the eclipse in admin mode (windows users) Go to your eclipse folder location -> open eclipse.ini file then make sure to match following.
从布局中删除所有错误和警告。确保您在管理模式(Windows 用户)下运行 eclipse 转到您的 eclipse 文件夹位置 -> 打开 eclipse.ini 文件,然后确保匹配以下内容。
-Dosgi.requiredJavaVersion=1.6-Xms512m-Xmx1024m
this may help you a little bit.
这可能会对你有所帮助。
and
和
Change Target SDK in your manifest to 18 for the time being to avoid the crashes. Issue is with android-19. Wait for another update before switching back.
暂时将清单中的 Target SDK 更改为 18 以避免崩溃。问题在于 android-19。在切换回来之前等待另一个更新。