aboutsummaryrefslogtreecommitdiffstats
path: root/checks/timer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'checks/timer.cpp')
-rw-r--r--checks/timer.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/checks/timer.cpp b/checks/timer.cpp
index 1bdaebb7f..aaea4b361 100644
--- a/checks/timer.cpp
+++ b/checks/timer.cpp
@@ -1,5 +1,5 @@
#include "timer.h"
-#include <botan/time.h>
+#include <chrono>
#include <iomanip>
Timer::Timer(const std::string& n, u32bit e_mul) :
@@ -32,7 +32,8 @@ void Timer::stop()
u64bit Timer::get_clock()
{
- return Botan::get_nanoseconds_clock();
+ auto now = std::chrono::high_resolution_clock::now().time_since_epoch();
+ return std::chrono::duration_cast<std::chrono::nanoseconds>(now).count();
}
std::ostream& operator<<(std::ostream& out, Timer& timer)