stats: avoid unneccessary work