Split frame metrics functionality into a separate unit

Bug: 117921091
Test: all tests should pass
Change-Id: I2b06bf124dc2af9768e8c58af4d7b7b37274f661
5 files changed