From 22bfb31fb22de7d25bccbecbfd2d087fff88ed6f Mon Sep 17 00:00:00 2001 From: Michal Bloch Date: Wed, 28 May 2025 21:59:34 +0200 Subject: [PATCH] benchmark debug Change-Id: I42c1866ef96f513e579bb2ac78b12feb67603f92 Signed-off-by: Michal Bloch --- tests/api_tests/test_benchmark_add.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/api_tests/test_benchmark_add.cpp b/tests/api_tests/test_benchmark_add.cpp index 8892793..3a52333 100644 --- a/tests/api_tests/test_benchmark_add.cpp +++ b/tests/api_tests/test_benchmark_add.cpp @@ -36,6 +36,7 @@ void callback(int result, void *userdata) } -- calls_remaining; waiting_for_reply = false; +std::cout << "callback wrocil" << std::endl; } gboolean periodic_check (gpointer data) @@ -46,13 +47,16 @@ gboolean periodic_check (gpointer data) } if (!calls_remaining) { +std::cout << "ostatni plomien zgasl" << std::endl; g_main_loop_quit(mainloop); return TRUE; } +std::cout << "idle, zapuszczam sleepa zeby sie template zregenerowal" << std::endl; waiting_for_reply = true; subsession_remove_user(UID, SUBSESSION_NAME.data(), nullptr, nullptr); std::this_thread::sleep_for(sleep_duration); +std::cout << "sleep DONER. robie nowego Add calla" << std::endl; start_timestamp = Clock::now(); subsession_add_user_fixed_size(UID, SUBSESSION_NAME.data(), IMAGE_SIZE, callback, nullptr); return TRUE; @@ -72,6 +76,7 @@ int main(int argc, char **argv) const auto idle_id = g_idle_add(periodic_check, nullptr); mainloop = g_main_loop_new(nullptr, false); +std::cout << "achtung. zapuszczam mainloope" << std::endl; g_main_loop_run(mainloop); std::cout << "Waited an average of " << total_duration.count() / CALLS_TO_MAKE << "ms per subsession add" << std::endl; -- 2.34.1