[C++-sig] Compile times using Boost::python.

Ralf W. Grosse-Kunstleve rwgk at yahoo.com
Wed Jun 4 23:48:48 CEST 2003

--- Kerim Borchaev <warkid at hotbox.ru> wrote:
>    System P4-1800, 512Mb.
>    Project consists of 12 files(~12 classes, 100-200 methods).
>    Compiling it with MSVC7 takes 2 minutes.
>    Isn't in too long?

I also wish compilation would go faster, but if you look at a preprocessed file
you will not be surprised anymore.

> What are your numbers?


>    How can I speed it up?

The way I view it:

1. Boost.Python is highly efficient in minimizing the work for the programmer
(expensive in terms of money) by using the available computing resources (cheap
in comparison).

2. Once you have your (run)time-consuming core algorithms implemented in C++
and wrapped with Boost.Python you can spend most of your time working with the
much more pleasant Python language. I am sometimes going for weeks without

If I have to recompile I am using SCons which supports parallel builds (the -j
option). Amazingly, our latest dual-CPU PC (for <$3k) allows me to use -j 4 and
is indeed about 3.8 times faster than compiling with one CPU. I hear this is
due to hyper-threading.


Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).

More information about the Cplusplus-sig mailing list