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

Unified Diff: ui/events/latency_info.h

Issue 123563002: Remove gpu side LatencyInfo merging (Closed) Base URL: http://git.chromium.org/chromium/src.git@gpu-per-event-latency-6-small
Patch Set: fix mac_rel compiler error. Move kMaxLatencyInfoNumber to .cc file Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/common/view_messages.h ('k') | ui/events/latency_info.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/latency_info.h
diff --git a/ui/events/latency_info.h b/ui/events/latency_info.h
index 3e50cc4f80c127b917513b65a07ebf7d29ab5571..96f76fbb890ffe179fb61e3a5d37249e5693a47b 100644
--- a/ui/events/latency_info.h
+++ b/ui/events/latency_info.h
@@ -7,6 +7,7 @@
#include <map>
#include <utility>
+#include <vector>
#include "base/basictypes.h"
#include "base/time/time.h"
@@ -87,6 +88,16 @@ struct EVENTS_BASE_EXPORT LatencyInfo {
~LatencyInfo();
+ // Returns true if the vector |latency_info| is valid. Returns false
+ // if it is not valid and log the |referring_msg|.
+ // This function is mainly used to check the latency_info vector that
+ // is passed between processes using IPC message has reasonable size
+ // so that we are confident the IPC message is not corrupted/compromised.
+ // This check will go away once the IPC system has better built-in scheme
+ // for corruption/compromise detection.
+ static bool Verify(const std::vector<LatencyInfo>& latency_info,
+ const char* referring_msg);
+
// Merges the contents of another LatencyInfo into this one.
void MergeWith(const LatencyInfo& other);
« no previous file with comments | « content/common/view_messages.h ('k') | ui/events/latency_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698