Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r81146 - in sandbox/big_number/libs/multiprecision: doc doc/html doc/html/boost_multiprecision/indexes doc/html/boost_multiprecision/tut/floats performance
From: john_at_[hidden]
Date: 2012-11-02 09:07:42


Author: johnmaddock
Date: 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
New Revision: 81146
URL: http://svn.boost.org/trac/boost/changeset/81146

Log:
Update MPFR docs with performance comparison.
Text files modified:
   sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s01.html | 4
   sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s02.html | 4
   sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s03.html | 4
   sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s04.html | 4
   sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/tut/floats/mpfr_float.html | 81 +++++++++++++++++++++++++++++++++++++++
   sandbox/big_number/libs/multiprecision/doc/html/index.html | 2
   sandbox/big_number/libs/multiprecision/doc/multiprecision.qbk | 10 ++++
   sandbox/big_number/libs/multiprecision/performance/sf_performance.cpp | 6 ++
   8 files changed, 104 insertions(+), 11 deletions(-)

Modified: sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s01.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s01.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s01.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -13,9 +13,9 @@
 <div class="spirit-nav">
 <a accesskey="p" href="../indexes.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../indexes.html"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a><a accesskey="n" href="s02.html"><img src="../../images/next.png" alt="Next"></a>
 </div>
-<div class="section id964891">
+<div class="section id958426">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id964891"></a>Function Index</h3></div></div></div>
+<a name="id958426"></a>Function Index</h3></div></div></div>
 <p><a class="link" href="s01.html#idx_id_0">A</a> <a class="link" href="s01.html#idx_id_1">B</a> <a class="link" href="s01.html#idx_id_2">C</a> <a class="link" href="s01.html#idx_id_3">D</a> <a class="link" href="s01.html#idx_id_4">E</a> <a class="link" href="s01.html#idx_id_5">F</a> <a class="link" href="s01.html#idx_id_7">I</a> <a class="link" href="s01.html#idx_id_8">L</a> <a class="link" href="s01.html#idx_id_9">M</a> <a class="link" href="s01.html#idx_id_12">P</a> <a class="link" href="s01.html#idx_id_13">R</a> <a class="link" href="s01.html#idx_id_14">S</a> <a class="link" href="s01.html#idx_id_15">T</a> <a class="link" href="s01.html#idx_id_17">Z</a></p>
 <div class="variablelist"><dl class="variablelist">
 <dt>

Modified: sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s02.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s02.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s02.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -13,9 +13,9 @@
 <div class="spirit-nav">
 <a accesskey="p" href="s01.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../indexes.html"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a><a accesskey="n" href="s03.html"><img src="../../images/next.png" alt="Next"></a>
 </div>
-<div class="section id966945">
+<div class="section id962951">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id966945"></a>Class Index</h3></div></div></div>
+<a name="id962951"></a>Class Index</h3></div></div></div>
 <p><a class="link" href="s02.html#idx_id_20">C</a> <a class="link" href="s02.html#idx_id_22">E</a> <a class="link" href="s02.html#idx_id_24">G</a> <a class="link" href="s02.html#idx_id_25">I</a> <a class="link" href="s02.html#idx_id_27">M</a> <a class="link" href="s02.html#idx_id_28">N</a> <a class="link" href="s02.html#idx_id_33">T</a></p>
 <div class="variablelist"><dl class="variablelist">
 <dt>

Modified: sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s03.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s03.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s03.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -13,9 +13,9 @@
 <div class="spirit-nav">
 <a accesskey="p" href="s02.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../indexes.html"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a><a accesskey="n" href="s04.html"><img src="../../images/next.png" alt="Next"></a>
 </div>
-<div class="section id969084">
+<div class="section id963368">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id969084"></a>Typedef Index</h3></div></div></div>
+<a name="id963368"></a>Typedef Index</h3></div></div></div>
 <p><a class="link" href="s03.html#idx_id_38">C</a> <a class="link" href="s03.html#idx_id_43">I</a> <a class="link" href="s03.html#idx_id_44">L</a> <a class="link" href="s03.html#idx_id_45">M</a> <a class="link" href="s03.html#idx_id_50">S</a> <a class="link" href="s03.html#idx_id_51">T</a> <a class="link" href="s03.html#idx_id_52">U</a></p>
 <div class="variablelist"><dl class="variablelist">
 <dt>

Modified: sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s04.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s04.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/indexes/s04.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -12,9 +12,9 @@
 <div class="spirit-nav">
 <a accesskey="p" href="s03.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../indexes.html"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a>
 </div>
-<div class="section id970084">
+<div class="section id964368">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id970084"></a>Index</h3></div></div></div>
+<a name="id964368"></a>Index</h3></div></div></div>
 <p><a class="link" href="s04.html#idx_id_54">A</a> <a class="link" href="s04.html#idx_id_55">B</a> <a class="link" href="s04.html#idx_id_56">C</a> <a class="link" href="s04.html#idx_id_57">D</a> <a class="link" href="s04.html#idx_id_58">E</a> <a class="link" href="s04.html#idx_id_59">F</a> <a class="link" href="s04.html#idx_id_60">G</a> <a class="link" href="s04.html#idx_id_61">I</a> <a class="link" href="s04.html#idx_id_62">L</a> <a class="link" href="s04.html#idx_id_63">M</a> <a class="link" href="s04.html#idx_id_64">N</a> <a class="link" href="s04.html#idx_id_65">O</a> <a class="link" href="s04.html#idx_id_66">P</a> <a class="link" href="s04.html#idx_id_67">R</a> <a class="link" href="s04.html#idx_id_68">S</a> <a class="link" href="s04.html#idx_id_69">T</a> <a class="link" href="s04.html#idx_id_70">U</a> <a class="link" href="s04.html#idx_id_71">Z</a></p>
 <div class="variablelist"><dl class="variablelist">
 <dt>

Modified: sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/tut/floats/mpfr_float.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/tut/floats/mpfr_float.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/boost_multiprecision/tut/floats/mpfr_float.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -70,8 +70,81 @@
           It can only be used at fixed precision, and should only be used for lower
           digit counts. Note that we can not guarentee that using <code class="computeroutput"><span class="identifier">allocate_stack</span></code>
           won't cause any calls to mpfr's allocation routines, as mpfr may call these
- inside it's own code.
+ inside it's own code. The following table gives an idea of the performance
+ tradeoff's at 50 decimal digits precision[2]</sup></a>:
         </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Type
+ </p>
+ </th>
+<th>
+ <p>
+ Bessel function evaluation, relative times
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">mpfr_float_backend</span><span class="special">&lt;</span><span class="number">50</span><span class="special">,</span> <span class="identifier">allocate_static</span><span class="special">&gt;,</span>
+ <span class="identifier">et_on</span><span class="special">&gt;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ 1.0 (5.5s)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">mpfr_float_backend</span><span class="special">&lt;</span><span class="number">50</span><span class="special">,</span> <span class="identifier">allocate_static</span><span class="special">&gt;,</span>
+ <span class="identifier">et_off</span><span class="special">&gt;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ 1.05 (5.8s)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">mpfr_float_backend</span><span class="special">&lt;</span><span class="number">50</span><span class="special">,</span> <span class="identifier">allocate_dynamic</span><span class="special">&gt;,</span>
+ <span class="identifier">et_on</span><span class="special">&gt;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ 1.05 (5.8s)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">mpfr_float_backend</span><span class="special">&lt;</span><span class="number">50</span><span class="special">,</span> <span class="identifier">allocate_dynamic</span><span class="special">&gt;,</span>
+ <span class="identifier">et_off</span><span class="special">&gt;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ 1.16 (6.4s)
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
 <div class="note"><table border="0" summary="Note">
 <tr>
 <td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
@@ -176,6 +249,12 @@
 </pre>
 <p>
         </p>
+<div class="footnotes">
+<br><hr style="width:100; align:left;">
+<div id="ftn.boost_multiprecision.tut.floats.mpfr_float.f0" class="footnote"><p>[2]
+ Compiled with VC++10 and /Ox, with MPFR-3.0.0 and MPIR-2.3.0
+ </p></div>
+</div>
 </div>
 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
 <td align="left"></td>

Modified: sandbox/big_number/libs/multiprecision/doc/html/index.html
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/html/index.html (original)
+++ sandbox/big_number/libs/multiprecision/doc/html/index.html 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -124,7 +124,7 @@
 </div>
 </div>
 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
-<td align="left"><p><small>Last revised: November 01, 2012 at 18:56:42 GMT</small></p></td>
+<td align="left"><p><small>Last revised: November 02, 2012 at 13:02:30 GMT</small></p></td>
 <td align="right"><div class="copyright-footer"></div></td>
 </tr></table>
 <hr>

Modified: sandbox/big_number/libs/multiprecision/doc/multiprecision.qbk
==============================================================================
--- sandbox/big_number/libs/multiprecision/doc/multiprecision.qbk (original)
+++ sandbox/big_number/libs/multiprecision/doc/multiprecision.qbk 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -767,6 +767,16 @@
 expense of growing the size of `mpfr_float_backend`. It can only be used at fixed precision, and
 should only be used for lower digit counts. Note that we can not guarentee that using `allocate_stack`
 won't cause any calls to mpfr's allocation routines, as mpfr may call these inside it's own code.
+The following table gives an idea of the performance tradeoff's at 50 decimal digits
+precision[footnote Compiled with VC++10 and /Ox, with MPFR-3.0.0 and MPIR-2.3.0]:
+
+[table
+[[Type][Bessel function evaluation, relative times]]
+[[`number<mpfr_float_backend<50, allocate_static>, et_on>`][1.0 (5.5s)]]
+[[`number<mpfr_float_backend<50, allocate_static>, et_off>`][1.05 (5.8s)]]
+[[`number<mpfr_float_backend<50, allocate_dynamic>, et_on>`][1.05 (5.8s)]]
+[[`number<mpfr_float_backend<50, allocate_dynamic>, et_off>`][1.16 (6.4s)]]
+]
 
 [note This type only provides `numeric_limits` support when the precision is fixed at compile time.]
 

Modified: sandbox/big_number/libs/multiprecision/performance/sf_performance.cpp
==============================================================================
--- sandbox/big_number/libs/multiprecision/performance/sf_performance.cpp (original)
+++ sandbox/big_number/libs/multiprecision/performance/sf_performance.cpp 2012-11-02 09:07:39 EDT (Fri, 02 Nov 2012)
@@ -282,10 +282,14 @@
 #ifdef TEST_MPFR
 #if MPFR_VERSION<MPFR_VERSION_NUM(3,0,0)
    time_proc("mpfr_float_50", test_bessel<boost::multiprecision::mpfr_float_50>, 1);
- time_proc("mpfr_float_50 (no expression templates", test_bessel<number<mpfr_float_backend<50>, et_off> >, 1);
+ time_proc("mpfr_float_50 (no expression templates)", test_bessel<number<mpfr_float_backend<50>, et_off> >, 1);
+ time_proc("static_mpfr_float_50", test_bessel<number<mpfr_float_backend<50, allocate_stack>, et_on> >, 1);
+ time_proc("static_mpfr_float_50 (no expression templates)", test_bessel<number<mpfr_float_backend<50, allocate_stack>, et_off> >, 1);
 #else
    time_proc("mpfr_float_50", test_bessel<boost::multiprecision::mpfr_float_50>, mpfr_buildopt_tls_p() ? 3 : 1);
    time_proc("mpfr_float_50 (no expression templates", test_bessel<number<mpfr_float_backend<50>, et_off> >, mpfr_buildopt_tls_p() ? 3 : 1);
+ time_proc("static_mpfr_float_50", test_bessel<number<mpfr_float_backend<50, allocate_stack>, et_on> >, mpfr_buildopt_tls_p() ? 3 : 1);
+ time_proc("static_mpfr_float_50 (no expression templates)", test_bessel<number<mpfr_float_backend<50, allocate_stack>, et_off> >, mpfr_buildopt_tls_p() ? 3 : 1);
 #endif
 #endif
 #ifdef TEST_MPF


Boost-Commit 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