Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(342)

Side by Side Diff: content/common/gpu/client/command_buffer_metrics.h

Issue 1095893002: gpu: Fix some context lost marking glitches+leaks and add UMA stats (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_COMMON_GPU_CLIENT_COMMAND_BUFFER_METRICS_H_
6 #define CONTENT_COMMON_GPU_CLIENT_COMMAND_BUFFER_METRICS_H_
7
8 #include <string>
9
10 #include "gpu/command_buffer/common/constants.h"
11
12 namespace content {
13
14 enum CommandBufferContextType {
15 // Don't add new values before _MAX_ENUM to keep the histogram consistent.
Ken Russell (switch to Gerrit) 2015/04/24 02:39:41 Is this comment correct? Should it read "before" o
16 BROWSER_COMPOSITOR_ONSCREEN_CONTEXT,
17 BROWSER_OFFSCREEN_MAINTHREAD_CONTEXT,
18 RENDER_COMPOSITOR_CONTEXT,
19 RENDER_WORKER_CONTEXT,
20 RENDERER_MAINTHREAD_CONTEXT,
21 GPU_VIDEO_ACCELERATOR_CONTEXT,
22 OFFSCREEN_VIDEO_CAPTURE_CONTEXT,
23 OFFSCREEN_CONTEXT_FOR_WEBGL,
24 CONTEXT_TYPE_UNKNOWN,
25 OFFSCREEN_CONTEXT_FOR_TESTING = CONTEXT_TYPE_UNKNOWN,
26 // Add new values above this point.
Ken Russell (switch to Gerrit) 2015/04/24 02:39:41 Above this point or above CONTEXT_TYPE_UNKNOWN?
no sievers 2015/04/24 18:52:47 Done.
27 CONTEXT_TYPE_MAX_ENUM = CONTEXT_TYPE_UNKNOWN
28 // not reported
29 };
30
31 std::string CommandBufferContextTypeToString(CommandBufferContextType type);
32
33 void UmaRecordContextInitFailed(CommandBufferContextType type);
34
35 void UmaRecordContextLost(CommandBufferContextType type,
36 gpu::error::Error error,
37 gpu::error::ContextLostReason reason);
38
39 } // namespace content
40
41 #endif // CONTENT_COMMON_GPU_CLIENT_COMMAND_BUFFER_METRICS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698