about summary refs log tree commit diff homepage
path: root/lib/Support/Timer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Support/Timer.cpp')
-rw-r--r--lib/Support/Timer.cpp24
1 files changed, 3 insertions, 21 deletions
diff --git a/lib/Support/Timer.cpp b/lib/Support/Timer.cpp
index 0e727bb4..4e52feb5 100644
--- a/lib/Support/Timer.cpp
+++ b/lib/Support/Timer.cpp
@@ -9,32 +9,14 @@
 
 #include "klee/Config/Version.h"
 #include "klee/Internal/Support/Timer.h"
-
 #include "klee/Internal/System/Time.h"
 
 using namespace klee;
-using namespace llvm;
-
-#if LLVM_VERSION_CODE >= LLVM_VERSION(4, 0)
 
 WallTimer::WallTimer() {
-  start = util::getWallTimeVal();
+  start = time::getWallTime();
 }
 
-uint64_t WallTimer::check() {
-  auto now = util::getWallTimeVal();
-  return std::chrono::duration_cast<std::chrono::microseconds>(now -
-    start).count();
+time::Span WallTimer::check() {
+  return time::Span(time::getWallTime() - start);
 }
-
-#else
-
-WallTimer::WallTimer() {
-  startMicroseconds = util::getWallTimeVal().usec();
-}
-
-uint64_t WallTimer::check() {
-  return util::getWallTimeVal().usec() - startMicroseconds;
-}
-
-#endif