Comment

Comment by daniel-cussen

Skylinesort appears to beat radix sort when the data is clustered, as it caches better, which is especially true when the number of unique elements is low.

The other thing about it that's better is that Skylinesort is the only sorting algorithm that is downward-concave, i.e. it takes less time to sort a list of size a (keeping clustering constant) than it takes to sort two lists of size a/2. In other words, it shows economies of scale. It has been a long-remarked paradox that sorting algorithms take longer per element when there's more elements.

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton