On Wed, Oct 31, 2012 at 12:58:18PM -0700, Alfred Perlstein wrote:
> It seems like the new compiler likes to get up to ~200+MB resident when 
> building some basic things in our tree.
> Unfortunately this causes smaller machines (VMs) to take days because of 
> swap thrashing.

You could try reducing data seg size (ulimit -d) to something matching
"RAM" size.  GCC has two parameters to try to keep its memory usage
"reasonable":

http://gcc.gnu.org/onlinedocs/gcc-4.2.4/gcc/Optimize-Options.html
'ggc-min-expand' and 'ggc-min-heapsize'.

ggc-min-expand
        ...
        If getrlimit is available, the notion of "RAM" is the smallest of
        actual RAM and RLIMIT_DATA
ggc-min-heapsize
        The default is the smaller of RAM/8, RLIMIT_RSS, or a limit which
        tries to ensure that RLIMIT_DATA or RLIMIT_AS are not exceeded

I don't know if Clang/LLVM has something similar or not.

-- 
-- David  (obr...@freebsd.org)
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Reply via email to