ANN: blist 1.2.0

Daniel Stutzbach daniel at stutzbachenterprises.com
Fri Jul 23 01:52:28 EDT 2010


On Thu, Jul 22, 2010 at 6:52 PM, Terry Reedy <tjreedy at udel.edu> wrote:

> Another sort of issue will be code maintainability. Two algorithms is
> potentially more problems than one. To me, that partly depends on how well
> factored the current code is.
>

Two algorithms is more code than one algorithm.  No way around that. :-)

Radix sort is a relatively simple sorting algorithm, so the extra complexity
is not too bad.  Once I have a patch ready, others can decide if the
additional complexity is worth the performance boost.


> It would be best is rsort were a switch replacement for timsort after all
> preparations (such as decorate) were done.
>

Yes, that's pretty much what I have in mind.  In pseudo-code:

sort:
    decorate()
    if all_correct_type and n > 40:
        radix_sort()
    else
        timsort()
    undecorate()


> And that is about all I can think of.


Thank you for the thoughts.  I appreciate them!
--
Daniel Stutzbach, Ph.D.
President, Stutzbach Enterprises, LLC <http://stutzbachenterprises.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100723/2a809dd9/attachment.html>


More information about the Python-list mailing list