diff options
author | Richard Linden <none@none> | 2013-07-15 11:06:22 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2013-07-15 11:06:22 -0700 |
commit | c03e366a6022d13fcf7b7e502daff8c72f7b64ee (patch) | |
tree | 6f92e21824332b5357f8befe4c978b83dbaa1aef /indra/newview/lltexturefetch.cpp | |
parent | 27de692bd7b297c9cd0fd6abcdee4b3e2486ec52 (diff) | |
parent | 11e14cd3b0f58225a96b9b7a9839a7f030fe4045 (diff) |
Automated merge with https://bitbucket.org/lindenlab/viewer-interesting
Diffstat (limited to 'indra/newview/lltexturefetch.cpp')
-rwxr-xr-x | indra/newview/lltexturefetch.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index 0390649a1c..d85247c4ec 100755 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -64,9 +64,9 @@ #include "bufferarray.h" #include "bufferstream.h" -bool LLTextureFetchDebugger::sDebuggerEnabled = false ; -LLTrace::SampleStatHandle<> LLTextureFetch::sCacheHitRate("texture_cache_hits"); -LLTrace::SampleStatHandle<> LLTextureFetch::sCacheReadLatency("texture_cache_read_latency"); +bool LLTextureFetchDebugger::sDebuggerEnabled = false; +LLTrace::EventStatHandle<LLUnit<F32, LLUnits::Percent> > LLTextureFetch::sCacheHitRate("texture_cache_hits"); +LLTrace::EventStatHandle<LLUnit<F64, LLUnits::Milliseconds> > LLTextureFetch::sCacheReadLatency("texture_cache_read_latency"); ////////////////////////////////////////////////////////////////////////////// @@ -1251,7 +1251,7 @@ bool LLTextureFetchWorker::doWork(S32 param) LL_DEBUGS("Texture") << mID << ": Cached. Bytes: " << mFormattedImage->getDataSize() << " Size: " << llformat("%dx%d",mFormattedImage->getWidth(),mFormattedImage->getHeight()) << " Desired Discard: " << mDesiredDiscard << " Desired Size: " << mDesiredSize << LL_ENDL; - sample(LLTextureFetch::sCacheHitRate, 100.f); + record(LLTextureFetch::sCacheHitRate, LLUnits::Ratio::fromValue(1)); } else { @@ -1269,7 +1269,7 @@ bool LLTextureFetchWorker::doWork(S32 param) } // fall through - sample(LLTextureFetch::sCacheHitRate, 0.f); + record(LLTextureFetch::sCacheHitRate, LLUnits::Ratio::fromValue(0)); } } @@ -1483,7 +1483,7 @@ bool LLTextureFetchWorker::doWork(S32 param) mGetReason.clear(); LL_DEBUGS("Texture") << "HTTP GET: " << mID << " Offset: " << mRequestedOffset << " Bytes: " << mRequestedSize - << " Bandwidth(kbps): " << mFetcher->getTextureBandwidth() << "/" << mFetcher->mMaxBandwidth + << " Bandwidth(kbps): " << mFetcher->getTextureBandwidth().value() << "/" << mFetcher->mMaxBandwidth << LL_ENDL; // Will call callbackHttpGet when curl request completes @@ -2762,10 +2762,10 @@ bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, discard_level = worker->mDecodedDiscard; raw = worker->mRawImage; aux = worker->mAuxImage; - F32 cache_read_time = worker->mCacheReadTime; + LLUnit<F32, LLUnits::Seconds> cache_read_time = worker->mCacheReadTime; if (cache_read_time != 0.f) { - sample(sCacheReadLatency, cache_read_time * 1000.f); + record(sCacheReadLatency, cache_read_time); } res = true; LL_DEBUGS("Texture") << id << ": Request Finished. State: " << worker->mState << " Discard: " << discard_level << LL_ENDL; @@ -2891,7 +2891,7 @@ S32 LLTextureFetch::update(F32 max_time_ms) mNetworkQueueMutex.lock(); // +Mfnq mMaxBandwidth = band_width; - add(LLStatViewer::TEXTURE_KBIT, mHTTPTextureBits); + add(LLStatViewer::TEXTURE_NETWORK_DATA_RECEIVED, mHTTPTextureBits); mHTTPTextureBits = 0; mNetworkQueueMutex.unlock(); // -Mfnq |