Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext

Comparisons to Other Open Source Libraries

We've run our performance tests both for our own code, and against other open source implementations of the same functions. The results are presented below to give you a rough idea of how they all compare. In order to give a more-or-less level playing field our test data was screened against all the libraries being tested, and any unsupported domains removed, likewise for any test cases that gave large errors or unexpected non-finite values.

[Caution] Caution

You should exercise extreme caution when interpreting these results, relative performance may vary by platform, the tests use data that gives good code coverage of our code, but which may skew the results towards the corner cases. Finally, remember that different libraries make different choices with regard to performance verses numerical stability.

The first results compare standard library functions to Boost equivalents with MSVC-14.0:

Table 20.7. Library Comparison with Microsoft Visual C++ version 14.0 on Windows x64

Function

boost 1.61

math.h

cbrt
(85/85 tests selected)

1.00
(45ns)

1.44
(65ns)

cyl_bessel_j (integer order)
(267/268 tests selected)

1.00
(103ns)

2.11
(217ns)

cyl_neumann (integer order)
(428/428 tests selected)

1.57
(225ns)

1.00
(143ns)

erf
(950/950 tests selected)

1.10
(23ns)

1.00
(21ns)

erfc
(950/950 tests selected)

1.00
(22ns)

3.36
(74ns)

expm1
(80/80 tests selected)

1.00
(10ns)

1.10
(11ns)

lgamma
(400/400 tests selected)

1.00
(73ns)

1.74
(127ns)

log1p
(80/80 tests selected)

1.08
(14ns)

1.00
(13ns)

tgamma
(400/400 tests selected)

1.00
(77ns)

12.12
(933ns)


On Linux with GCC, we can also compare to the TR1 functions, and to GSL and RMath:

[table_Library_Comparison_with_GNU_C_version_5_1_0_on_linux]

And finally we can compare the statistical distributions to GSL, RMath and DCDFLIB:

[table_Distribution_performance_comparison_with_GNU_C_version_5_1_0_on_linux]


PrevUpHomeNext