diff options
author | Richard Linden <none@none> | 2012-10-01 19:39:04 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2012-10-01 19:39:04 -0700 |
commit | 14b1b0b2bb6bac5bc688cc4d14c33f1b680dd3b4 (patch) | |
tree | 74942f4fef955b5a55031650146e745bbc4ccd6f /indra/newview/llviewerstats.cpp | |
parent | b1baf982b1bd41a150233d0a28d3601226924c65 (diff) |
SH-3275 WIP Run viewer metrics for object update messages
cleaned up API
samplers are now value types with copy-on-write buffers under the hood
removed coupling with LLThread
Diffstat (limited to 'indra/newview/llviewerstats.cpp')
-rwxr-xr-x | indra/newview/llviewerstats.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index b1aeaef91d..e2b09a1902 100755 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -62,7 +62,7 @@ #include "llmeshrepository.h" //for LLMeshRepository::sBytesReceived -LLTrace::Stat<F32> STAT_KBIT("kbitstat"), +LLTrace::Rate<F32> STAT_KBIT("kbitstat"), STAT_LAYERS_KBIT("layerskbitstat"), STAT_OBJECT_KBIT("objectkbitstat"), STAT_ASSET_KBIT("assetkbitstat"), @@ -263,8 +263,7 @@ LLViewerStats::LLViewerStats() : mNumNewObjectsStat("numnewobjectsstat"), mNumSizeCulledStat("numsizeculledstat"), mNumVisCulledStat("numvisculledstat"), - mLastTimeDiff(0.0), - mSampler(LLThread::getTraceData()->createSampler()) + mLastTimeDiff(0.0) { for (S32 i = 0; i < ST_COUNT; i++) { @@ -467,12 +466,12 @@ void update_statistics() stats.mFPSStat.addValue(1); F32 layer_bits = (F32)(gVLManager.getLandBits() + gVLManager.getWindBits() + gVLManager.getCloudBits()); - STAT_LAYERS_KBIT.sample(layer_bits/1024.f); + STAT_LAYERS_KBIT.add(layer_bits/1024.f); //stats.mLayersKBitStat.addValue(layer_bits/1024.f); - STAT_OBJECT_KBIT.sample(gObjectBits/1024.f); + STAT_OBJECT_KBIT.add(gObjectBits/1024.f); //stats.mObjectKBitStat.addValue(gObjectBits/1024.f); stats.mVFSPendingOperations.addValue(LLVFile::getVFSThread()->getPending()); - STAT_ASSET_KBIT.sample(gTransferManager.getTransferBitsIn(LLTCT_ASSET)/1024.f); + STAT_ASSET_KBIT.add(gTransferManager.getTransferBitsIn(LLTCT_ASSET)/1024.f); //stats.mAssetKBitStat.addValue(gTransferManager.getTransferBitsIn(LLTCT_ASSET)/1024.f); gTransferManager.resetTransferBitsIn(LLTCT_ASSET); @@ -510,7 +509,7 @@ void update_statistics() static LLFrameTimer texture_stats_timer; if (texture_stats_timer.getElapsedTimeF32() >= texture_stats_freq) { - STAT_TEXTURE_KBIT.sample(LLViewerTextureList::sTextureBits/1024.f); + STAT_TEXTURE_KBIT.add(LLViewerTextureList::sTextureBits/1024.f); //stats.mTextureKBitStat.addValue(LLViewerTextureList::sTextureBits/1024.f); stats.mTexturePacketsStat.addValue(LLViewerTextureList::sTexturePackets); gTotalTextureBytes += LLViewerTextureList::sTextureBits / 8; |