I'm writing a custom pass for LLVM/Clang, and recompiling tends to take a while and use a lot of memory. I've heard that the gold linker (1) takes less time and (2) uses less memory than the standard ld linker.
Is there a way to pass flags into the LLVM/Clang build process and change to the gold linker? As per this answer, I've been attempting to use an override file, but I don't seem to be having a lot of success.
I'll also note that I'm compiling the latest Clang/LLVM build (4.0) using Clang 3.9; I don't mind switching back to GCC if necessary but would rather avoid it.