Imported Upstream version 1.72.0
[platform/upstream/boost.git] / libs / sort / doc / html / sort / single_thread / spreadsort / sort_hpp / rationale / unstable_sort.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
4 <title>Unstable Sorting</title>
5 <link rel="stylesheet" href="../../../../../../../../../doc/src/boostbook.css" type="text/css">
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7 <link rel="home" href="../../../../../index.html" title="Boost.Sort">
8 <link rel="up" href="../rationale.html" title="Rationale">
9 <link rel="prev" href="why_spreadsort.html" title="Why spreadsort?">
10 <link rel="next" href="optimization.html" title="Unused X86 optimization">
11 </head>
12 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13 <table cellpadding="2" width="100%"><tr>
14 <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../../boost.png"></td>
15 <td align="center"><a href="../../../../../../../../../index.html">Home</a></td>
16 <td align="center"><a href="../../../../../../../../../libs/libraries.htm">Libraries</a></td>
17 <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
18 <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
19 <td align="center"><a href="../../../../../../../../../more/index.htm">More</a></td>
20 </tr></table>
21 <hr>
22 <div class="spirit-nav">
23 <a accesskey="p" href="why_spreadsort.html"><img src="../../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../rationale.html"><img src="../../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../../index.html"><img src="../../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="optimization.html"><img src="../../../../../../../../../doc/src/images/next.png" alt="Next"></a>
24 </div>
25 <div class="section">
26 <div class="titlepage"><div><div><h6 class="title">
27 <a name="sort.single_thread.spreadsort.sort_hpp.rationale.unstable_sort"></a><a class="link" href="unstable_sort.html" title="Unstable Sorting">Unstable
28             Sorting</a>
29 </h6></div></div></div>
30 <p>
31               Making a <a href="http://en.wikipedia.org/wiki/Radix_sort" target="_top">radix
32               sort</a> stable requires the usage of an external copy of the data.
33               A stable hybrid algorithm also requires a stable comparison-based algorithm,
34               and these are generally slow. LSD <a href="http://en.wikipedia.org/wiki/Radix_sort" target="_top">radix
35               sort</a> uses an external copy of the data, and provides stability,
36               along with likely being faster (than a stable hybrid sort), so that's
37               probably a better way to go for integer and floating-point types. It
38               might make sense to make a stable version of <code class="literal"><code class="computeroutput"><a class="link" href="../../../../../boost/sort/spreadsort/string_s_idm46048202990736.html" title="Function template string_sort">string_sort</a></code></code>
39               using external memory, but for simplicity this has been left out for
40               now.
41             </p>
42 </div>
43 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
44 <td align="left"></td>
45 <td align="right"><div class="copyright-footer">Copyright &#169; 2014-2017 Steven
46       Ross, Francisco Tapia, Orson Peters<p>
47         Distributed under the <a href="http://boost.org/LICENSE_1_0.txt" target="_top">Boost
48         Software License, Version 1.0</a>.
49       </p>
50 </div></td>
51 </tr></table>
52 <hr>
53 <div class="spirit-nav">
54 <a accesskey="p" href="why_spreadsort.html"><img src="../../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../rationale.html"><img src="../../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../../index.html"><img src="../../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="optimization.html"><img src="../../../../../../../../../doc/src/images/next.png" alt="Next"></a>
55 </div>
56 </body>
57 </html>