From: Mikhail Grigorev Date: Sun, 30 Oct 2022 10:29:27 +0000 (+0500) Subject: Implemenated sched_yield function for Windows X-Git-Tag: upstream/1.7.4~1868 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=6417e59aadc1f4276141c93c03b72d044f41b425;p=pkg%2Fggml%2Fsources%2Fwhisper.cpp Implemenated sched_yield function for Windows --- diff --git a/ggml.c b/ggml.c index bd11cc20..c59822d8 100644 --- a/ggml.c +++ b/ggml.c @@ -44,6 +44,11 @@ static int pthread_create(pthread_t* out, void* unused, thread_ret_t(*func)(void static int pthread_join(pthread_t thread, void* unused) { return (int) WaitForSingleObject(thread, INFINITE); } + +int sched_yield (void) { + Sleep (0); + return 0; +} #else #include #include