SERVER-10026 add memory usage stats to sort and print stats upon error