Log stats while processing a trace.