From f7cb6ee0d67afaed499cec9e8e8d0d481a65dd29 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Sat, 1 Jun 2019 12:31:17 -0700 Subject: lib: Simplify implementation of uhd::get_system_time() to use uhd::get_system_time() is currently only used in USRP1 code, and it turns out that our "optimized", platform-dependent implementation still is a little slower than straight-up chrono. We therefore remove all the special cases, and replace them with a single, standard solution. --- host/tests/CMakeLists.txt | 6 ++++++ host/tests/system_time_test.cpp | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'host/tests') diff --git a/host/tests/CMakeLists.txt b/host/tests/CMakeLists.txt index 769c09796..e476eb61b 100644 --- a/host/tests/CMakeLists.txt +++ b/host/tests/CMakeLists.txt @@ -156,6 +156,12 @@ UHD_ADD_NONAPI_TEST( ${CMAKE_SOURCE_DIR}/lib/rfnoc/nocscript/ ) +UHD_ADD_NONAPI_TEST( + TARGET "system_time_test.cpp" + EXTRA_SOURCES + "${CMAKE_SOURCE_DIR}/lib/utils/system_time.cpp" +) + UHD_ADD_NONAPI_TEST( TARGET "nocscript_ftable_test.cpp" EXTRA_SOURCES diff --git a/host/tests/system_time_test.cpp b/host/tests/system_time_test.cpp index 3f4f8a814..5e39604c8 100644 --- a/host/tests/system_time_test.cpp +++ b/host/tests/system_time_test.cpp @@ -4,8 +4,8 @@ // SPDX-License-Identifier: GPL-3.0+ // -#include "system_time.hpp" #include +#include #include #include #include -- cgit v1.2.3