Implement the jank monitor.

The jank monitor watches janks on the browser UI and IO thread
using content::responsiveness::MetricSource. The monitor watches task
and native event on a separate sequence (i.e. the "monitor thread").
When the monitor observes task or event running for longer than a
threshold, it notifies the user class about the start and stop of the
jank through the Observer interface.

Bug: 904785
Test: unit_tests: JankMonitorTest.*
Change-Id: I0de7601e7564718e438d3063ce0bfd387bde6675
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1601019
Commit-Queue: Chinglin Yu <chinglinyu@chromium.org>
Reviewed-by: Erik Chen <erikchen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#671626}
5 files changed