From 85632fab9c8f30b4651f06fd75e1ba5881226e6c Mon Sep 17 00:00:00 2001 From: "jar@chromium.org" Date: Mon, 10 May 2010 16:35:47 +0000 Subject: Switch to using TimeTicks for profiling and histograms Avoid using wall clock time, which can be changed by the user, or impacted by Daylight Savings transitions etc. BUG=14193 r=eroman Review URL: http://codereview.chromium.org/1253005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46821 0039d316-1c4b-4281-b951-d872f2087c98 --- net/base/file_stream_win.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'net/base/file_stream_win.cc') diff --git a/net/base/file_stream_win.cc b/net/base/file_stream_win.cc index 1ad9a34..6a6db90 100644 --- a/net/base/file_stream_win.cc +++ b/net/base/file_stream_win.cc @@ -74,14 +74,15 @@ class FileStream::AsyncContext : public MessageLoopForIO::IOHandler { FileStream::AsyncContext::~AsyncContext() { is_closing_ = true; bool waited = false; - base::Time start = base::Time::Now(); + base::TimeTicks start = base::TimeTicks::Now(); while (callback_) { waited = true; MessageLoopForIO::current()->WaitForIOCompletion(INFINITE, this); } if (waited) { // We want to see if we block the message loop for too long. - UMA_HISTOGRAM_TIMES("AsyncIO.FileStreamClose", base::Time::Now() - start); + UMA_HISTOGRAM_TIMES("AsyncIO.FileStreamClose", + base::TimeTicks::Now() - start); } } -- cgit v1.1