Skip to content

Commit

Permalink
Implement a faster sort algorithm
Browse files Browse the repository at this point in the history
This is a complete rewrite of the standard sort algorithm. The new algorithm
is a simplified variant of TimSort. In summary, the changes are:

* Improved performance, especially on partially sorted inputs.
* Performs less comparisons on both random and partially sorted inputs.
* Decreased the size of temporary memory: the new sort allocates 4x less.
  • Loading branch information
Stjepan Glavina committed Dec 7, 2016
1 parent ff261d3 commit c8d73ea
Show file tree
Hide file tree
Showing 4 changed files with 480 additions and 315 deletions.
4 changes: 2 additions & 2 deletions src/libcollections/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@
#![feature(placement_in)]
#![feature(placement_new_protocol)]
#![feature(shared)]
#![feature(slice_get_slice)]
#![feature(slice_patterns)]
#![feature(specialization)]
#![feature(staged_api)]
#![feature(step_by)]
#![feature(trusted_len)]
#![feature(unicode)]
#![feature(unique)]
#![feature(slice_get_slice)]
#![feature(untagged_unions)]
#![cfg_attr(test, feature(rand, test))]

#![no_std]
Expand Down
Loading

0 comments on commit c8d73ea

Please sign in to comment.