Skip to content

Why is std::list<>::sort so slow ??? A (much!) faster way to sort lists. #1650

Discussion options

You must be logged in to vote

I think implementations of std::(forward_)list::<>::sort generally use merge sort. And merge sort is expected because the standard requires that these sort's are stable.

If the requirement of stability were removed, we would be able to use the combination of quick sort and merge sort.

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by StephanTLavavej
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants