Added more cache testing and sorting for lists