Temporarily removed sorting, and reduced memory usage.