Report/Preprint
Cite …

Formally Verifying an Efficient Sorter

Bernhard Beckert  ORCID iD icon 1, Peter Sanders ORCID iD icon 2, Mattías Ulbrich ORCID iD icon 1, Sascha Witt 2 and Julian Wiesler
1 Institute of Information Security and Dependability (KASTEL), Karlsruhe Institute of Technology (KIT)
2 Institute of Theoretical Informatics (ITI), Karlsruhe Institute of Technology (KIT)
DOI: 10.5445/IR/1000167846
PDF published on Jan 29, 2024
Abstract

In this experience report, we present the complete formal verification of a Java implementation of inplace superscalar sample sort (ips4o) using the KeY program verification system. As ips4o is one of the fastest general purpose sorting algorithms, this is an important step towards a collection of basic toolbox components that are both provably correct and highly efficient. At the same time, it is an important case study of how careful, highly efficient implementations of complicated algorithms can be formally verified directly. We provide an analysis of which features of the KeY system and its verification calculus are instrumental in enabling algorithm verification without any compromise on algorithm efficiency.