summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorRichard Nelson <none@none>2010-08-13 16:00:14 -0700
committerRichard Nelson <none@none>2010-08-13 16:00:14 -0700
commite427c671f036de1addf90fa9a2ed09035b099392 (patch)
tree16e59e1bf81a25002125bcd0e53a84017a9826ac /indra
parent143bf98d7356d0424eac114cbf35e8738410ed5e (diff)
fixed fast timer average frame time rollover error
Diffstat (limited to 'indra')
-rw-r--r--indra/llcommon/llfasttimer_class.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/llcommon/llfasttimer_class.cpp b/indra/llcommon/llfasttimer_class.cpp
index dfbae09864..e9ac709254 100644
--- a/indra/llcommon/llfasttimer_class.cpp
+++ b/indra/llcommon/llfasttimer_class.cpp
@@ -474,9 +474,9 @@ void LLFastTimer::NamedTimer::accumulateTimings()
int hidx = cur_frame % HISTORY_NUM;
timerp->mCountHistory[hidx] = timerp->mTotalTimeCounter;
- timerp->mCountAverage = (timerp->mCountAverage * cur_frame + timerp->mTotalTimeCounter) / (cur_frame+1);
+ timerp->mCountAverage = ((U64)timerp->mCountAverage * cur_frame + timerp->mTotalTimeCounter) / (cur_frame+1);
timerp->mCallHistory[hidx] = timerp->getFrameState().mCalls;
- timerp->mCallAverage = (timerp->mCallAverage * cur_frame + timerp->getFrameState().mCalls) / (cur_frame+1);
+ timerp->mCallAverage = ((U64)timerp->mCallAverage * cur_frame + timerp->getFrameState().mCalls) / (cur_frame+1);
}
}
}