Linking times

Hi,

Just a brief follow-up on my link time issue: It was caused by excessive trashing; I tried rebuilding on a box with 8 gigs of RAM and observed the memory load while linking clang.exe: It peaked at 5 gigabytes memory, so now I’ve written this piece of info into the LLVM/Windows document that I posted earlier (I have already made a substantial number of corrections in the document). All in all, it took the 2 gig box about 5 hours to link clang.exe :slight_smile:

I must say that I am once again surprised about GNU tools. I’d expect the linker to use perhaps 100 megabytes of memory as it only needs to record where the BLOBs are in the input files and then, during one of the final passes, copy each binary block to the output file - without caching it in memory. I do suspect that GNU ld indiscriminantly reads in everything under the assumption that people never link that large files.

Cheers,
Mikael

– Love Thy Frog!

Do you specify CMAKE_BUILD_TYPE
if you are using cmake?

2012/05/27 18:21 “Mikael Lyngvig” <mikael@lyngvig.org>:

No, I use the command:

cmake -G “MinGW Makefiles” …\llvm

Cheers,
Mikael
– Love Thy Frog!

2012/5/27 NAKAMURA Takumi <geek4civic@gmail.com>