Switched size_t to int64_t to prevent type mismatch in call to max.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73988 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Lang Hames 2009-06-23 19:49:23 +00:00
parent a67efd1226
commit b2889959c4

View File

@ -182,11 +182,11 @@ void Timer::sum(const Timer &T) {
/// currently active timers, which will be printed when the timer group prints /// currently active timers, which will be printed when the timer group prints
/// ///
void Timer::addPeakMemoryMeasurement() { void Timer::addPeakMemoryMeasurement() {
size_t MemUsed = getMemUsage(); int64_t MemUsed = getMemUsage();
for (std::vector<Timer*>::iterator I = ActiveTimers->begin(), for (std::vector<Timer*>::iterator I = ActiveTimers->begin(),
E = ActiveTimers->end(); I != E; ++I) E = ActiveTimers->end(); I != E; ++I)
(*I)->PeakMem = std::max((*I)->PeakMem, MemUsed-(*I)->PeakMemBase); (*I)->PeakMem = std::max((*I)->PeakMem, (int64_t)MemUsed-(*I)->PeakMemBase);
} }
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//