- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I've searched some tips to make the Composer linking faster. Compiling is obviously influenced by optimizations, but I don't know what makes the compiler slower at linking time.
I have some dynamic linking times of 1 min, that it's too much if you are changing only 1 file at the each time.
Is that normal?
Thanks in advance!
1 Solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Just an addition for tests with disablingIPO (/Qipo-) to see if this helps. Please add also LINKER option /qnoipo (Configuration Properties > Linker > Optimization [Intel C++] > Interprocedural Optimization: No (/qnoipo). The compiler option alone does not always disable interprocedural optimization.
Let me know if this makes any difference.
Regards,
Hubert
Link Copied
9 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jaime,
Are you running Visual Studio? Are you sure that it's just a matter of linking rather than a complete rebuild of all project files in caseonly one single file was being changed?
Regards, Hubert
Are you running Visual Studio? Are you sure that it's just a matter of linking rather than a complete rebuild of all project files in caseonly one single file was being changed?
Regards, Hubert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If a single file is part of a library which is part of a larger project all other files depending on the library need to be rebuilt. Also, make sure you are using precompiled headers.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, I know it, but it takes 1 minute (compiling with 8gb in a Xeon with 8 cores) only linking without taking into account the compilation time. I dont use precompiled headers.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
As I said, consider using precompiled headers. You can also experiment with Link Time Code Generation (/LTCG). Also, if you are using /Qipo, that can slow down linking as well, try switching to /Qip and compare code performance. If /Qip does not reduce performance consider using /Qip instead of /Qipo.
Finally, try using faster storage like 10k RPM HDD or SSD or setup your build environment to work in ram disk.
Finally, try using faster storage like 10k RPM HDD or SSD or setup your build environment to work in ram disk.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Using/Qipo- doesn't decrease link time. In fact, it takes the same time in debug and in release.
Which things in the code make the linker to be very slow? It happens in only very concrete modules
PS: I can't manage to create/use precompiled headers
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Just an addition for tests with disablingIPO (/Qipo-) to see if this helps. Please add also LINKER option /qnoipo (Configuration Properties > Linker > Optimization [Intel C++] > Interprocedural Optimization: No (/qnoipo). The compiler option alone does not always disable interprocedural optimization.
Let me know if this makes any difference.
Regards,
Hubert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
>>...Is that normal?..
Could you post all Linker options? It is really hard to suggest anything in your case.
Ihad even longer times when some import & dynamic libraries werelocated on a network drive. Another
case was related toa poor performance of aSubversion.
Could you post all Linker options? It is really hard to suggest anything in your case.
Ihad even longer times when some import & dynamic libraries werelocated on a network drive. Another
case was related toa poor performance of aSubversion.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Few generic ideas:
- if you are using antivirus, try to temporarily disable realtime scanning and see whether that helps
- if you are connected to VPN try disconnecting before you build
Finally, if you cannot bother to test with precompiled headers to see whether it gets any faster, then I am afraid we cannot offer more help than we already did.
- if you are using antivirus, try to temporarily disable realtime scanning and see whether that helps
- if you are connected to VPN try disconnecting before you build
Finally, if you cannot bother to test with precompiled headers to see whether it gets any faster, then I am afraid we cannot offer more help than we already did.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
#9 That helped. Linking time reduced a 95%! Now I have normal times!
Thanks a lot

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page