Boost logo

Boost-Build :

From: Robert Ramey (ramey_at_[hidden])
Date: 2007-08-03 04:21:46

For sometime I've wanted to subject the serialization library to execution
time profiing. In the past I have spent significant time in program runtime
optimization and have found such profiling indispensible.

So I built the serialization tests with

bjam --dump_tests --toolset=gcc-3.3 variant=profile ...

Hoping against hope that I would endup with a profile output in each test

Well, my hopes weren't realized as I'm aware there there hasn't been much
interest in this area.

However, good news was that the executables were built with the proper
options and when run generated the required gmon.out file.

Bad news is the following:

a) the gmon.out file is created in directory from which bjam is run. When
running a series of tests, each gmon.out file gets overwritten by its
successor test.

b) I could re-run the executable in each test directory to create a new
gmon.out - but the executable is removed after the test to save space.


I find I can save the executable with a bjam
switch --preserve-test_targets - which is ok

Then I can craft a simple script which will run each test in its directory
and then run gprof to prepare the table.

If I decide I want to spend the effort, I can make these tables easy to

So I'm satisfied.

But I wonder is there some bjam magic which can be helpful with this
process? bjam gurus are encouraged to respond.

Robert Ramey

Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at