From 92dda4b8b5c9fb0e4a3295f16aae4cd016210ca6 Mon Sep 17 00:00:00 2001 From: Emmanuel Pacaud Date: Tue, 1 Dec 2026 20:24:26 +0000 Subject: [PATCH] tests: yield in the write lock test start barrier The busy wait loop made the test very slow under valgrind, which runs one thread at a time: the spinning thread kept running until the end of its time slice before the other threads could reach the barrier. Co-Authored-By: Claude Opus 5.5 --- tests/fake.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/fake.c b/tests/fake.c index ea020d31f..d13970512 100644 --- a/tests/fake.c +++ b/tests/fake.c @@ -966,7 +966,7 @@ write_lock_thread (gpointer user_data) /* Start together, in order to race on the first lazy builds */ g_atomic_int_inc (data->n_ready); while (g_atomic_int_get (data->n_ready) < WRITE_LOCK_N_THREADS) - ; + g_thread_yield (); _collect (ARV_DOM_NODE (data->genicam), data->results);