First pass at sorting.