summaryrefslogtreecommitdiffstats
path: root/components/tracing/tracing_messages.h
diff options
context:
space:
mode:
authoryurys <yurys@chromium.org>2014-11-17 02:57:56 -0800
committerCommit bot <commit-bot@chromium.org>2014-11-17 10:58:26 +0000
commitd57ba6fe68ea4b8bfbdc403ea7b3a3e74e38b03f (patch)
treee651b362c50989a2ea343ed39904090da75e0f9e /components/tracing/tracing_messages.h
parent5f52b6d2c2476159c45f2d5c53df336824c057e0 (diff)
downloadchromium_src-d57ba6fe68ea4b8bfbdc403ea7b3a3e74e38b03f.zip
chromium_src-d57ba6fe68ea4b8bfbdc403ea7b3a3e74e38b03f.tar.gz
chromium_src-d57ba6fe68ea4b8bfbdc403ea7b3a3e74e38b03f.tar.bz2
Report trace buffer usage as number of events, not only percentage
The total event count will be used later to show progress indicator when retrieving recorded events. The progress will be estimated as total events received divided by total buffer size. BUG=426117 Review URL: https://codereview.chromium.org/717083003 Cr-Commit-Position: refs/heads/master@{#304404}
Diffstat (limited to 'components/tracing/tracing_messages.h')
-rw-r--r--components/tracing/tracing_messages.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/components/tracing/tracing_messages.h b/components/tracing/tracing_messages.h
index ff891a0..18041cc 100644
--- a/components/tracing/tracing_messages.h
+++ b/components/tracing/tracing_messages.h
@@ -7,6 +7,7 @@
#include <vector>
#include "base/basictypes.h"
+#include "base/debug/trace_event_impl.h"
#include "base/sync_socket.h"
#include "ipc/ipc_channel_handle.h"
#include "ipc/ipc_message_macros.h"
@@ -15,6 +16,11 @@
#define IPC_MESSAGE_START TracingMsgStart
+IPC_STRUCT_TRAITS_BEGIN(base::debug::TraceLogStatus)
+IPC_STRUCT_TRAITS_MEMBER(event_capacity)
+IPC_STRUCT_TRAITS_MEMBER(event_count)
+IPC_STRUCT_TRAITS_END()
+
// Sent to all child processes to enable trace event recording.
IPC_MESSAGE_CONTROL3(TracingMsg_BeginTracing,
std::string /* category_filter_str */,
@@ -37,7 +43,7 @@ IPC_MESSAGE_CONTROL0(TracingMsg_DisableMonitoring)
IPC_MESSAGE_CONTROL0(TracingMsg_CaptureMonitoringSnapshot)
// Sent to all child processes to get trace buffer fullness.
-IPC_MESSAGE_CONTROL0(TracingMsg_GetTraceBufferPercentFull)
+IPC_MESSAGE_CONTROL0(TracingMsg_GetTraceLogStatus)
// Sent to all child processes to set watch event.
IPC_MESSAGE_CONTROL2(TracingMsg_SetWatchEvent,
@@ -69,7 +75,6 @@ IPC_MESSAGE_CONTROL1(TracingHostMsg_TraceDataCollected,
IPC_MESSAGE_CONTROL1(TracingHostMsg_MonitoringTraceDataCollected,
std::string /*json trace data*/)
-// Reply to TracingMsg_GetTraceBufferPercentFull.
-IPC_MESSAGE_CONTROL1(TracingHostMsg_TraceBufferPercentFullReply,
- float /*trace buffer percent full*/)
-
+// Reply to TracingMsg_GetTraceLogStatus.
+IPC_MESSAGE_CONTROL1(TracingHostMsg_TraceLogStatusReply,
+ base::debug::TraceLogStatus /*status of the trace log*/)