Index: src/libplatform/default-platform.cc |
diff --git a/src/libplatform/default-platform.cc b/src/libplatform/default-platform.cc |
index b5b8571dbc9a9e4d059d91bb641bf5a6ff81f858..1ac52f919f3f4889037512e332a5b07fba25146c 100644 |
--- a/src/libplatform/default-platform.cc |
+++ b/src/libplatform/default-platform.cc |
@@ -9,6 +9,7 @@ |
#include "src/base/logging.h" |
#include "src/base/platform/platform.h" |
+#include "src/base/platform/time.h" |
#include "src/base/sys-info.h" |
#include "src/libplatform/worker-thread.h" |
@@ -106,4 +107,9 @@ void DefaultPlatform::CallOnForegroundThread(v8::Isolate* isolate, Task* task) { |
main_thread_queue_[isolate].push(task); |
} |
+ |
+double DefaultPlatform::MonotonicallyIncreasingTime() { |
+ return base::TimeTicks::HighResolutionNow().ToInternalValue() / |
+ static_cast<double>(base::Time::kMicrosecondsPerSecond); |
+} |
} } // namespace v8::platform |