From 5f4c1c01de8f0da24956c1c931d3ffe7410b5b78 Mon Sep 17 00:00:00 2001 From: David Seifert Date: Sat, 30 Oct 2021 18:35:53 +0200 Subject: [PATCH] pthread_yield -> sched_yield (glibc 2.34) Bug: https://bugs.gentoo.org/808049 Upstream: https://github.com/ROCm-Developer-Tools/roctracer/pull/63 --- src/core/memory_pool.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/memory_pool.h b/src/core/memory_pool.h index fe2f1a6..fbd9060 100644 --- a/src/core/memory_pool.h +++ b/src/core/memory_pool.h @@ -24,6 +24,7 @@ THE SOFTWARE. #define MEMORY_POOL_H_ #include +#include #include #include @@ -152,7 +153,7 @@ class MemoryPool { } static void sync_reader(const consumer_arg_t* arg) { - while(arg->valid.load() == true) PTHREAD_CALL(pthread_yield()); + while(arg->valid.load() == true) PTHREAD_CALL(sched_yield()); } static void* reader_fun(void* consumer_arg) { -- 2.33.1