How can you speed up Eclipse?

2018-12-31 07:32发布

How can you make the experience with Eclipse faster?

For instance: I disable all the plugins I don't need (Mylyn, Subclipse, …).

Instead of using a plugin for Mercurial, I configure TortoiseHG as an external tool.

30条回答
有味是清欢
2楼-- · 2018-12-31 07:59

Eclipse loads plug-ins lazily, and most common plug-ins, like Subclipse, don't do anything if you don't use them. They don't slow Eclipse down at all during run time, and it won't help you to disable them. In fact, Mylyn was shown to reduce Eclipse's memory footprint when used correctly.

I run Eclipse with tons of plug-ins without any performance penalty at all.

  • Try disabling compiler settings that you perhaps don't need (e.g. the sub-options under "parameter is never read).
  • Which version of Eclipse are you using? Older versions were known to be slow if you upgraded them over and over again, because they got their plug-ins folder inflated with duplicate plug-ins (with different versions). This is not a problem in version 3.4.
  • Use working-sets. They work better than closing projects, particularly if you need to switch between sets of projects all the time.

It's not only the memory that you need to increase with the -Xmx switch, it's also the perm gen size. I think that problem was solved in Eclipse 3.4.

查看更多
情到深处是孤独
3楼-- · 2018-12-31 08:00

Thanks for the hints. These options (mentioned above) helped me a lot:

Windows:

Increasing memory & regarding to my updated Java version in eclipse.ini:

-Dosgi.requiredJavaVersion=1.6
-Xms256m
-Xmx512m
-XX:PermSize=512m
-XX:MaxPermSize=512M
-Xverify:none

Linux / Ubuntu:

Using

update-alternatives --config java
查看更多
柔情千种
4楼-- · 2018-12-31 08:01

If you use Maven and ivy do check out their consoles in case they are hogging processing during builds. I use ivy and on top of that I have certain JAR files (internal) changing with same version, so it has to workout all the time to fetch them.

If you have defined you project on a network drive then you will also experience lag during build/read/write type of processes.

  • Disable/uninstall plugins you don't need.

  • Close perpective that you don't need

  • Close unused database connections

查看更多
伤终究还是伤i
5楼-- · 2018-12-31 08:02

Not to be underrated is having a fast machine. 16-32 GB of RAM, SSD and a decent processor... and who0o0om there you go.

查看更多
荒废的爱情
6楼-- · 2018-12-31 08:02

Try this too, it will improve the performance:

cleaning up indexes - {workspace path}.metadata.plugins\org.eclipse.jdt.core cleaning up history - {workspace path}.metadata.plugins\org.eclipse.core.resources.history

Cleaning the above folders will not impact the project files.

查看更多
妖精总统
7楼-- · 2018-12-31 08:03

I implemented a plug-in to configure which features to be loaded in runtime to improve the performance and reduce the conflict among different plug-ins.

You may have installed many features into your Eclipse, such as Android development tools, C/C++ development tools, PHP, SVN, Git and ClearCase plug-ins. Hence Eclipse is heavy and costs a lot of memory, and some of them are not often used.

So you could use my tool to create different runtime policies, such as one that has Android, Git and base Eclipse, another one contains C/C++, SVN and base Eclipse. Next time Eclipse would only load the specified features if you're using the policy that only has Android and Git.

You are welcome to try it and give me the feedback. :)

The name of that tool is Equinox Advanced Configurator.

查看更多
登录 后发表回答