Add the stats.retained and stats.arenas.<i>.retained statistics.

This resolves #367.
7 files changed