This CL has two parts:
Part 1: This CL adds an experiment to base called
IsRunningCpuReductionExperiment. When enabled, several different
unrelated features will change their behavior to reduce overall CPU
consumption of chrome. As these features are unrelated, this experiment
must live in base as the only common dependency.
Part 2: This CL modifies 6 functions that emit UMA metrics to emit at
1/1000th of their current rate. Combined, the UMA metric emission from
these 6 functions are responsible for 0.33% of all CPU cycles on
ChromeOS, including time from non-chrome processes. This demonstrates
why the code in part 1 must live in base.
Future CLs will add more CPU-savings to the experiment before it is
enabled.
Bug: 1295441
Change-Id: I8202c5a1482ff66fc90a7bc64bb36b3cdc773130
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3449251
Reviewed-by: Ken Rockot <rockot@google.com>
Reviewed-by: Sunny Sachanandani <sunnyps@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Francois Pierre Doray <fdoray@chromium.org>
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Commit-Queue: Erik Chen <erikchen@chromium.org>
Cr-Commit-Position: refs/heads/main@{#969512}