Bug 1264820 - Measure IPC reply size in telemetry (r=mccr8)

This commit is contained in:
Bill McCloskey 2016-04-14 17:52:31 -07:00
Родитель 59edda43b7
Коммит b7e2b4e82e
2 изменённых файлов: 16 добавлений и 2 удалений

Просмотреть файл

@ -759,7 +759,7 @@ MessageChannel::Send(Message* aMsg)
{
if (aMsg->capacity() >= kMinTelemetryMessageSize) {
Telemetry::Accumulate(Telemetry::IPC_MESSAGE_SIZE,
nsCString(aMsg->name()), aMsg->capacity());
nsDependentCString(aMsg->name()), aMsg->capacity());
}
CxxStackFrame frame(*this, OUT_MESSAGE, aMsg);
@ -1059,7 +1059,7 @@ MessageChannel::Send(Message* aMsg, Message* aReply)
{
if (aMsg->capacity() >= kMinTelemetryMessageSize) {
Telemetry::Accumulate(Telemetry::IPC_MESSAGE_SIZE,
nsCString(aMsg->name()), aMsg->capacity());
nsDependentCString(aMsg->name()), aMsg->capacity());
}
nsAutoPtr<Message> msg(aMsg);
@ -1244,6 +1244,10 @@ MessageChannel::Send(Message* aMsg, Message* aReply)
MOZ_RELEASE_ASSERT(reply->is_sync());
*aReply = Move(*reply);
if (aReply->size() >= kMinTelemetryMessageSize) {
Telemetry::Accumulate(Telemetry::IPC_REPLY_SIZE,
nsDependentCString(aMsg->name()), aReply->capacity());
}
return true;
}

Просмотреть файл

@ -10521,6 +10521,16 @@
"keyed": true,
"description": "Measures the size of IPC messages by message name"
},
"IPC_REPLY_SIZE": {
"alert_emails": ["wmccloskey@mozilla.com"],
"bug_numbers": [1264820],
"expires_in_version": "55",
"kind": "exponential",
"high": 8000000,
"n_buckets": 50,
"keyed": true,
"description": "Measures the size of IPC messages by message name"
},
"MESSAGE_MANAGER_MESSAGE_SIZE": {
"alert_emails": ["wmccloskey@mozilla.com"],
"bug_numbers": [1260908],