最佳答案
对 Eclipse 速度影响最大的三个因素是:
- 使用最新版本的 Eclipse(2020-06 截至 2020 年 6 月 26 日)
请注意,David Balažic 的 comment(2014 年 7 月)与六年前的标准相矛盾:
The "same" workspace in Indigo (3.7.2) SR2 loads in 4 seconds, in Kepler SR2 (4.3.2) in 7 seconds and in Luna (4.4.0) in 10 seconds. All are Java EE bundles. Newer versions have more bundled plugins, but still the trend is obvious. (by "same" workspace I mean: same (additionally installed) plugins used, same projects checked out from version control).
使用最新的 JDK 启动它(在撰写本文时为 Java 14,这并不妨碍您在 Eclipse 项目中使用您想要的任何其他 JDK 进行编译:1.4.2, 1.5、1.6 旧...)
-vm jdk1.6.0_10\jre\bin\client\jvm.dll
配置 eclipse.ini(请参阅 this question for a complete eclipse.ini)
-Xms512m -Xmx4096m [...]
Xmx
参数是 Eclipse 将获得的内存量(简单来说)。使用 -Xmx4g
,它可以获得 4 GiB 的 RAM 等。
注意:
- 引用 jvm.dll 有以下优点:
- 启动画面会更快出现。
- 进程列表中是 Eclipse.exe,而不是 java.exe。
- 防火墙:Eclipse 希望访问 Internet 而不是 Java。
- 窗口管理品牌问题,尤其是在 Windows 和 Mac 上。
十二月2020年,Udo确认in the comments
From version 4.8 (Photon) an up there was a steady speed gain after each version.
The main platform was optimized every release to load faster, enable more features for the dark theme and to add more features for newer Java versions for the Java development tools.
Especially with-in the last 3 versions the startup time was increased a lot. There should be a significant increase in start-up time with the newest version of Eclipse 2020-12.In my experience it started a lot faster with each new version.
But: There are still plug-ins which do not follow the new way of using the Eclipse API and are therefore still slow to start.
Since the change to Java 11 as the minimum runtime version starting from Eclipse version 2020-09 at least the core system uses the newer features of the JVM. It is up to the providers of the other plug-ins to upgrade to newer APIs and to use the full power of modern CPUs (e.g. concurrent programming model).
另请参阅
- 为 Eclipse 提供正确数量的线程和正确数量的内存:Problem: Eclipse and the Eclipse indexer take up all my resources / CPU%
关于eclipse - 如何加速 Eclipse?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/316265/