summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorMonty Brandenberg <monty@lindenlab.com>2013-05-07 17:27:12 -0400
committerMonty Brandenberg <monty@lindenlab.com>2013-05-07 17:27:12 -0400
commit153c3443a53b499818fae09685024971aafb4b8e (patch)
tree002c24fdb1d1e89d656fbf7766dd3cc00859733f /indra/newview
parentaa855b18ecde2786c758ac27d2ddb049d0929d55 (diff)
parent960139aa6f02f90c6102d3c5d5c38b5ebe689f9c (diff)
SH-4162 Merge metrics repo into this branch and integrate
Pull cpu-based metrics into llcorehttp work to enable A/B testing. Simple merge.
Diffstat (limited to 'indra/newview')
-rwxr-xr-xindra/newview/llmeshrepository.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp
index 419613091a..2d4692be5b 100755
--- a/indra/newview/llmeshrepository.cpp
+++ b/indra/newview/llmeshrepository.cpp
@@ -98,7 +98,7 @@ U32 LLMeshRepository::sLODPending = 0;
U32 LLMeshRepository::sCacheBytesRead = 0;
U32 LLMeshRepository::sCacheBytesWritten = 0;
U32 LLMeshRepository::sPeakKbps = 0;
-LLDeadmanTimer LLMeshRepository::sQuiescentTimer(15.0);
+LLDeadmanTimer LLMeshRepository::sQuiescentTimer(15.0, true); // true -> gather cpu metrics
const U32 MAX_TEXTURE_UPLOAD_RETRIES = 5;
@@ -4420,9 +4420,9 @@ void LLMeshRepository::metricsProgress(unsigned int this_count)
void LLMeshRepository::metricsUpdate()
{
F64 started, stopped;
- U64 total_count;
-
- if (sQuiescentTimer.isExpired(0, started, stopped, total_count))
+ U64 total_count(U64L(0)), user_cpu(U64L(0)), sys_cpu(U64L(0));
+
+ if (sQuiescentTimer.isExpired(0, started, stopped, total_count, user_cpu, sys_cpu))
{
LLSD metrics;
@@ -4432,6 +4432,8 @@ void LLMeshRepository::metricsUpdate()
metrics["stop"] = stopped;
metrics["downloads"] = LLSD::Integer(total_count);
metrics["teleports"] = LLSD::Integer(metrics_teleport_start_count);
+ metrics["user_cpu"] = double(user_cpu) / 1.0e6;
+ metrics["sys_cpu"] = double(sys_cpu) / 1.0e6;
llinfos << "EventMarker " << metrics << llendl;
}
}