optimizing: Refactor statistics to use OptimizingCompilerStats helper

Remove all copies of 'MaybeRecordStat', replacing them with a single
OptimizingCompilerStats::MaybeRecordStat helper.

Change-Id: I83b96b41439dccece3eee2e159b18c95336ea933
18 files changed