llvm-dwp

To whom may concerned.

It is likely that there is a memory leak, for linking llvm-dev.

When I follow the the procedure of building swfit( github/swift instructment, clang-3.9 ), and the computer will nearly die during the step of linking llvm-dev.
It used out of the system memory( > 4 G ) and continue, without any sign of stop, to used the swap filesystem.

Regards,

Hi,

It used out of the system memory( > 4 G ) and continue, without any sign of stop, to used the swap filesystem.

This is pretty normal for a debug build. If you're on Linux, the
ld.gold linker is much more efficient than ld.bfd so switching to that
may help (how you do it is distribution-dependent).

Reducing the number of parallel threads can also help significantly.
The blunt hammer is "make -j1" or "ninja -j1" (1 is probably too
conservative, but is a starting point). If you're using ninja as the
build system, you can set CMake's LLVM_PARALLEL_LINK_JOBS variable to
limit just the memory-intensive linking phase.

But 4GB is pushing the limits either way. LLVM is a big project and
it's quite possible to hit swap with even 16GB of RAM.

Cheers.

Tim.