Boost logo

Boost-Build :

From: K. Noel Belcourt (kbelco_at_[hidden])
Date: 2006-09-05 00:42:26


Hi,

I just wanted to give you a feel for Bjam's memory footprint when
building a reasonably large application. On our Linux boxes

(uname -a) Linux machine 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56
EST 2006 x86_64 x86_64 x86_64 GNU/Linux

our build command
bjam --v2 -j3
...patience...
...found 61711 targets...
...updating 28632 targets...

left bjam with a 1.7Gb memory footprint, leaving very little memory
for the build phase on this 2Gb machine.

top - 22:28:53 up 17 days, 12:31, 2 users, load average: 1.55,
1.07, 0.73
Tasks: 88 total, 7 running, 81 sleeping, 0 stopped, 0 zombie
Cpu(s): 75.7% us, 9.3% sy, 0.0% ni, 13.0% id, 0.5% wa, 0.2% hi,
1.3% si
Mem: 2056420k total, 2042912k used, 13508k free, 4352k buffers
Swap: 4096564k total, 62792k used, 4033772k free, 85516k cached

   PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
6873 kbelco 17 0 42224 38m 2776 R 33.6 1.9 0:01.01 cc1plus
6882 kbelco 16 0 35100 31m 2656 R 23.9 1.6 0:00.72 cc1plus
6879 kbelco 16 0 32644 29m 2656 R 21.9 1.5 0:00.66 cc1plus
6858 kbelco 16 0 8324 1112 860 R 0.3 0.1 0:00.01 top
6564 kbelco 16 0 1739m 1.7g 524 S 0.0 85.1 6:18.45 bjam
6872 kbelco 17 0 1516 448 364 S 0.0 0.0 0:00.00 g++
6878 kbelco 17 0 1516 448 364 S 0.0 0.0 0:00.00 g++
6881 kbelco 18 0 1516 448 364 S 0.0 0.0 0:00.00 g++

Is there anyway I can get bjam to release some memory once the
dependency analysis is complete and it moves into the build phase?
With our applications, there are a significant number of dependencies
and I understand it takes lots of memory to do the dependency
analysis but I'd like to find a way to free up some memory for the
compiles and links. Many of our application exceed 500 Mb when
linked debug and with bjam holding ~80% of memory, the builds and
links run very slowly.

Any ideas?

-- Noel Belcourt


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk