summaryrefslogtreecommitdiff
path: root/indra/llcommon/llthread.cpp
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-09-28 10:45:14 -0700
committerRichard Linden <none@none>2012-09-28 10:45:14 -0700
commit38354e19063478c8cda0408547ad05023b457041 (patch)
treee2e5f1a6a10adc3b7d8bd5711e7eda9c89f6cf6a /indra/llcommon/llthread.cpp
parent07c4be092b276f0d7c14ba12872efb31c1f16764 (diff)
SH-3275 WIP Run viewer metrics for object update messages
created separate constructor for static allocation of sampler buffer fixed start/stop/resume semantics of samplers and added sampler time interval tracking
Diffstat (limited to 'indra/llcommon/llthread.cpp')
-rw-r--r--indra/llcommon/llthread.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/indra/llcommon/llthread.cpp b/indra/llcommon/llthread.cpp
index 2ff524d9ba..7384842627 100644
--- a/indra/llcommon/llthread.cpp
+++ b/indra/llcommon/llthread.cpp
@@ -32,6 +32,7 @@
#include "llmutex.h"
#include "lltimer.h"
+#include "lltrace.h"
#if LL_LINUX || LL_SOLARIS
#include <sched.h>
@@ -85,7 +86,7 @@ void *APR_THREAD_FUNC LLThread::staticRun(apr_thread_t *apr_threadp, void *datap
{
LLThread *threadp = (LLThread *)datap;
- sTraceData = new LLTrace::SlaveThreadTrace();
+ setTraceData(new LLTrace::SlaveThreadTrace());
#if !LL_DARWIN
sThreadIndex = threadp->mID;
@@ -100,6 +101,7 @@ void *APR_THREAD_FUNC LLThread::staticRun(apr_thread_t *apr_threadp, void *datap
threadp->mStatus = STOPPED;
delete sTraceData.get();
+ sTraceData = NULL;
return NULL;
}
@@ -311,3 +313,13 @@ void LLThread::wakeLocked()
mRunCondition->signal();
}
}
+
+LLTrace::ThreadTrace* LLThread::getTraceData()
+{
+ return sTraceData.get();
+}
+
+void LLThread::setTraceData( LLTrace::ThreadTrace* data )
+{
+ sTraceData = data;
+}