ls-summary: use a single O(n) pass through with awk