[GestureTransition] Record snapshot compression time in UMA
It's been seen in local traces that snapshot compression is expensive, and might compete with foreground work. THere are several experiments in progress to tackle that, for instance by lowering priority. Add a histogram to assess how much the lower priority impacts compression times. Bug: 369986099 Change-Id: I3741109ac2052117c4516a4f58bcee0f606a159c Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6281949 Commit-Queue: Benoit Lize <lizeb@chromium.org> Reviewed-by: Alexander Timin <altimin@chromium.org> Cr-Commit-Position: refs/heads/main@{#1422480}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
4d8565fb32
commit
20aa1bde86
content/browser/renderer_host/navigation_transitions
tools/metrics/histograms/metadata/navigation
@ -5,6 +5,7 @@
|
||||
#include "content/browser/renderer_host/navigation_transitions/navigation_entry_screenshot.h"
|
||||
|
||||
#include "base/feature_list.h"
|
||||
#include "base/metrics/histogram_macros.h"
|
||||
#include "content/browser/renderer_host/navigation_transitions/navigation_entry_screenshot_cache.h"
|
||||
#include "content/browser/renderer_host/navigation_transitions/navigation_transition_config.h"
|
||||
|
||||
@ -31,6 +32,7 @@ void CompressNavigationScreenshotOnWorkerThread(
|
||||
SkBitmap bitmap,
|
||||
bool supports_etc_non_power_of_two,
|
||||
CompressionDoneCallback done_callback) {
|
||||
SCOPED_UMA_HISTOGRAM_TIMER("Navigation.GestureTransition.CompressionTime");
|
||||
TRACE_EVENT0("navigation", "CompressNavigationScreenshotOnWorkerThread");
|
||||
|
||||
sk_sp<SkPixelRef> compressed_bitmap = nullptr;
|
||||
|
@ -1081,6 +1081,17 @@ chromium-metrics-reviews@google.com.
|
||||
</summary>
|
||||
</histogram>
|
||||
|
||||
<histogram name="Navigation.GestureTransition.CompressionTime" units="ms"
|
||||
expires_after="M140">
|
||||
<owner>lizeb@chromium.org</owner>
|
||||
<owner>clank-performance-team@google.com</owner>
|
||||
<summary>
|
||||
The time it takes to compress the navigation screenshot, on a background
|
||||
thread. Recorded on Android, each time a navigation screenshot is
|
||||
compressed.
|
||||
</summary>
|
||||
</histogram>
|
||||
|
||||
<histogram
|
||||
name="Navigation.GestureTransition.IgnoredInputCount.{Reason}.{Position}"
|
||||
units="count" expires_after="M140">
|
||||
|
Reference in New Issue
Block a user