We are currently maintaining a relatively large internal C++ project, but with the use of boost and template metaprogramming, we are experiencing a situation where compilation time is increased and operational efficiency decreases significantly.
There are many ways to reduce header dependencies, use pch, and other compilation times, but please let me know if you have the option to obtain profilers and statistics for the compilation process as a guide to what bottlenecks exist.
Your environment is
Windows 7 visual studio 2015 professional edition sp3
That's it.
Thank you for your cooperation.
c++ visual-studio build
Private compilation option link options are available.
cl.exe/Bt
link.exe /time
You can use the to determine how long it takes.This is only a private option, so please try it after recognizing the possibility of changing the specifications in the future.
Please recommend a few things
/MP
option/Zc:inline
Option Remove debug symbols that are deployed inline and are no longer needed/INCREMENTAL
option
/LTCG:INCREMENTAL
OptionIncremental Link to Generate Code on Link/DEBUG:FASTLINK
option for faster generation of debug symbol files (VS2015 SP1 or later)/MP
option/Zc:inline
Option Remove debug symbols that are deployed inline and are no longer needed/INCREMENTAL
option
/LTCG:INCREMENTAL
OptionIncremental Link to Generate Code on Link/DEBUG:FASTLINK
option for faster generation of debug symbol files (VS2015 SP1 or later)
I'm sorry, but the account registration process seems to have failed, and the email address at the time of the question was linked to another ID (this ID), so I couldn't access the account in question.Generally speaking, it is difficult to consolidate accounts.
With regard to the above questions, I understand from the compilation options you gave me that almost all the time is spent on LINK.Using that information as a clue, we reached the following page:
https://blogs.msdn.microsoft.com/vcblog/2013/10/29/the-visual-c-linker-best-practices-developer-iteration/
Using the 64-bit toolset during a 32-bit build significantly reduced link time (more than boost or template, it seems that there was not enough memory for code size augmentation).
© 2024 OneMinuteCode. All rights reserved.