Sort Race
Hantao Zhang, Baoluo Meng, Yiwen Liang

TL;DR
This paper extensively compares comparison-based internal sorting algorithms, especially quicksort and a custom mergesort, demonstrating their effectiveness on various data types and nearly sorted inputs, and provides a platform for testing sorting algorithms.
Contribution
It introduces optimized implementations of quicksort and mergesort that outperform existing versions, and offers a comprehensive experimental framework for sorting algorithm evaluation.
Findings
Quicksort is highly adaptive to nearly sorted data.
The custom mergesort outperforms Timsort on nearly sorted data.
The implementations outperform standard C library qsort functions.
Abstract
Sorting is one of the oldest computing problems and is still very important in the age of big data. Various algorithms and implementation techniques have been proposed. In this study, we focus on comparison based, internal sorting algorithms. We created 12 data types of various sizes for experiments and tested extensively various implementations in a single setting. Using some effective techniques, we discovered that quicksort is adaptive to nearly sorted inputs and is still the best overall sorting algorithm. We also identified which techniques are effective in timsort, one of the most popular and efficient sorting method based on natural mergesort, and created our version of mergesort, which runs faster than timsort on nearly sorted instances. Our implementations of quicksort and mergesort are different from other implementations reported in all textbooks or research articles, faster…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsParallel Computing and Optimization Techniques · Cloud Computing and Resource Management · Algorithms and Data Compression
