Call sched_yield for yieldcpu function on linux/osx please test
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3837 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
9b0bed1e7f
commit
9e16a5ccd8
|
@ -40,6 +40,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#ifdef _POSIX_THREADS
|
#ifdef _POSIX_THREADS
|
||||||
#include <pthread.h>
|
#include <pthread.h>
|
||||||
|
#include <sched.h>
|
||||||
#elif GEKKO
|
#elif GEKKO
|
||||||
#include <ogc/lwp_threads.h>
|
#include <ogc/lwp_threads.h>
|
||||||
#else
|
#else
|
||||||
|
@ -183,7 +184,7 @@ inline void YieldCPU()
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
YieldProcessor();
|
YieldProcessor();
|
||||||
#else
|
#else
|
||||||
// TODO: Implement for other platforms.
|
sched_yield();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue