summaryrefslogtreecommitdiff
path: root/indra/llcommon/llfasttimer.cpp
diff options
context:
space:
mode:
authorRichard Linden <none@none>2013-02-08 00:03:31 -0800
committerRichard Linden <none@none>2013-02-08 00:03:31 -0800
commite3700112f313f3570887047d5b56a661af0afac5 (patch)
treeb60aec4150f4282649f9ceacb93b70df32aed5fe /indra/llcommon/llfasttimer.cpp
parenteb6c8959ca5b8b3c100114d4d659a48bb4d56b2c (diff)
SH-3275 WIP interesting Update viewer metrics system to be more flexible
added debug output to BlockTimer
Diffstat (limited to 'indra/llcommon/llfasttimer.cpp')
-rw-r--r--indra/llcommon/llfasttimer.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/llcommon/llfasttimer.cpp b/indra/llcommon/llfasttimer.cpp
index e58c5c0f98..ba626bcc32 100644
--- a/indra/llcommon/llfasttimer.cpp
+++ b/indra/llcommon/llfasttimer.cpp
@@ -434,4 +434,12 @@ void TimeBlockAccumulator::reset( const TimeBlockAccumulator* other )
}
}
+LLUnit<LLUnits::Seconds, F64> BlockTimer::getElapsedTime()
+{
+ U64 total_time = TimeBlock::getCPUClockCount64() - mStartTime;
+
+ return (F64)total_time / (F64)TimeBlock::countsPerSecond();
+}
+
+
} // namespace LLTrace