简体   繁体   English

Windows与Linux的Ant性能较慢

[英]Ant performance Slow in Windows vs Linux

We have a large system with multiple ant targets. 我们有一个包含多个蚂蚁目标的大型系统。 The performance on Ant build (consists of javac,jarsigner,java tasks) is very slow (almost twice/thrice) in Windows vs Linux. 在Windows与Linux中,Ant构建(由javac,jarsigner,java任务组成)的性能非常慢(几乎两倍/三倍)。 Ant xmx is 512MB Ant xmx是512MB

Linux : Ubuntu 64 bit , 4 GB RAM, Intel Core2 Duo CPU E8400 @ 3.00GHz × 2 (desktop) Linux:Ubuntu 64位,4 GB RAM,Intel Core2 Duo CPU E8400 @ 3.00GHz×2(桌面)

Windows : Windows 7 64 bit, 4 GB RAM, Intel i7 2.8GHz (laptop) Windows:Windows 7 64位,4 GB RAM,Intel i7 2.8GHz(笔记本电脑)

Find below the comparison of time of few tasks (mostly javac) (in millisec) from Windows vs linux. 在下面找到Windows和Linux之间几个任务(主要是javac)(以毫秒为单位)的时间比较。

Windows Linux
117110  35033
32593   14300
10659   4107
9112    2704
8440    2464
3956    1844
3284    1635
2385    1091
1866    919
1722    752
1581    669
1529    579
1482    524
1468    478
1442    334

Are there any options to speed the performance in Windows? 有没有选择加快Windows的性能?

On further analysis, I saw that McAfee On-Access virus scan was running in my Windows 7 laptop. 在进一步分析中,我看到McAfee On-Access病毒扫描正在我的Windows 7笔记本电脑中运行。 On disabling it, the build time reduced by half (50% improvement). 在禁用它时,构建时间减少一半(改善50%)。

Another cause could be windows indexing service. 另一个原因可能是Windows索引服务。 In my case windows 10 it was windows defender and indexing service that consumed resources (mostly cpu). 在我的情况下,Windows 10是Windows防御者和索引服务,消耗资源(主要是CPU)。

In both cases you can exclude specific folders. 在这两种情况下,您都可以排除特定文件 you don't need to disable the services completely. 您不需要完全禁用服务。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM