Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(776)

Unified Diff: test/cctest/test-log.cc

Issue 1118533003: Make CPU profiler do not hog 100% of CPU. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Do not use Sleep on Windows Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« src/cpu-profiler.cc ('K') | « test/cctest/test-cpu-profiler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-log.cc
diff --git a/test/cctest/test-log.cc b/test/cctest/test-log.cc
index 2386cec55bafa77ee3b1074d1e4e7f135b9fbcae..7d7543ead5e2c4ebf3cb7712d888c75e27eeb98f 100644
--- a/test/cctest/test-log.cc
+++ b/test/cctest/test-log.cc
@@ -192,7 +192,7 @@ class LoopingJsThread : public LoopingThread {
"var j; for (var i=0; i<10000; ++i) { j = Math.sin(i); }");
}
context.Dispose();
- i::OS::Sleep(1);
+ i::OS::Sleep(v8::base::TimeDelta::FromMilliseconds(1));
}
}
};
@@ -212,7 +212,7 @@ class LoopingNonJsThread : public LoopingThread {
SignalRunning();
while (IsRunning()) {
i = std::sin(i);
- i::OS::Sleep(1);
+ i::OS::Sleep(v8::base::TimeDelta::FromMilliseconds(1));
}
}
};
« src/cpu-profiler.cc ('K') | « test/cctest/test-cpu-profiler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698