[转]Improving link time with IncrediBuild,减少联合编译器的链接是时间

本文提供了几种方法来提高IncrediBuild与Visual Studio在增量构建过程中的链接阶段速度,包括限制使用LTCG选项、减少并发Agent数量、禁用杀毒软件扫描、调整调试信息格式等。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

http://blog.youkuaiyun.com/yacper/article/details/4791092

 

重点:

不要用/LTCG

将debug信息设为/z7

 

IncrediBuild may, in some cases, take longer than Visual Studio to execute the link phase. This is related to the fact that IncrediBuild generates multiple PDB and IDB files when building (one for each concurrent Agent), while Visual Studio only generates one of each of these files.
If you are using Visual Studio .NET or 2005, try enabling IncrediLink (Agent Settings dialog, Build System page) to speed up incremental links. Read the product documentation for some considerations that need to be taken when using this mode.
The following suggestions may also help improve link speed:


1. Try to minimize use of the /LTCG linker option in local builds, since this option moves a significant portion of the build processing from the compilation phase to the linking phase, significantly impacting IncrediBuild's performance improvement.

尽量不用LTCG,一般情况下inrementalbuild

 

2. If the max. number of Agents allowed to participate in a build exceeds 12, decrease this option and then rebuild the project (this setting can be found in the Coordinator Settings dialog, Agent Assignment page).

agents设为12以下,物极必反,协调也需要cpu时间

 

3. If you are running a "live" anti-virus scanner (or any other file-scanning software), disable its operation on the project's intermediate and output folder or on typical intermediate file extensions (*.pdb, *.obj, *.idb, *.sbr, *.pch).

关掉杀毒软件的查询

 

4. If your typical build operation builds multiple projects in parallel, consider using the "Limit concurrent PDB instances" option (Agent Settings dialog, "Visual Studio Builds|Advanced" page). This will decrease the number of PDB files, speeding up builds, but will also limit the number of concurrent files from the same project configurationthat IncrediBuild will build at any single time.

这个不实用。


5. Make sure you are running the latest version of IncrediBuild.


6. Periodically rebuilding the project (even nightly) can reduce PDB fragmentation and help improve subsequent link times.

定时重编project,减少pdb的碎片。

7. Changing the debug information format to /Z7 can also help improve link times.

将debug信息设成z7,显然使用这个功能,就不能编辑并继续了,当然,这对于vc2005来说是无所谓的,因为05的c++就没这功能,哈哈

转载于:https://www.cnblogs.com/pulas/archive/2012/04/17/2454055.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值