From 240650f6a6336df8d3eb11b410cdcd332d8ad562 Mon Sep 17 00:00:00 2001 From: Kelebek1 Date: Sun, 10 Jul 2022 06:59:40 +0100 Subject: Rework CoreTiming --- src/tests/core/core_timing.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/tests') diff --git a/src/tests/core/core_timing.cpp b/src/tests/core/core_timing.cpp index e687416a8..894975e6f 100644 --- a/src/tests/core/core_timing.cpp +++ b/src/tests/core/core_timing.cpp @@ -9,6 +9,7 @@ #include #include #include +#include #include #include "core/core.h" @@ -25,13 +26,15 @@ u64 expected_callback = 0; std::mutex control_mutex; template -void HostCallbackTemplate(std::uintptr_t user_data, std::chrono::nanoseconds ns_late) { +std::optional HostCallbackTemplate(std::uintptr_t user_data, s64 time, + std::chrono::nanoseconds ns_late) { std::unique_lock lk(control_mutex); static_assert(IDX < CB_IDS.size(), "IDX out of range"); callbacks_ran_flags.set(IDX); REQUIRE(CB_IDS[IDX] == user_data); delays[IDX] = ns_late.count(); ++expected_callback; + return std::nullopt; } struct ScopeInit final { -- cgit v1.2.3