[go: nahoru, domu]

[jank] Initial implementation for injecting jank.

Introduce a new finch experiment that can be used to inject jank into
the main-thread. This only happens when the main-thread is handling
animation or scrolls. The jank is introduced by [occasionally] keeping
the main-thread busy before it starts an animation frame.

Bug: 1170814
Change-Id: I78cb06496ad4ecebca3ec20b19ebaca7283ef611
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2670899
Commit-Queue: Sadrul Chowdhury <sadrul@chromium.org>
Reviewed-by: Sami Kyöstilä <skyostil@chromium.org>
Cr-Commit-Position: refs/heads/master@{#856063}
diff --git a/cc/BUILD.gn b/cc/BUILD.gn
index 8d453858..23f3720 100644
--- a/cc/BUILD.gn
+++ b/cc/BUILD.gn
@@ -186,6 +186,8 @@
     "metrics/frame_sequence_tracker_collection.h",
     "metrics/frame_sorter.cc",
     "metrics/frame_sorter.h",
+    "metrics/jank_injector.cc",
+    "metrics/jank_injector.h",
     "metrics/jank_metrics.cc",
     "metrics/jank_metrics.h",
     "metrics/latency_ukm_reporter.cc",