UISIMULATOR: Trying to make it snappy for everyone. Remove forced thread yield in switch_thread which starves threads that call it alot especially on fast 64-bit machines (which could yield _alot_ of time away). I suspect that was a way to get I/O to run better before having an I/O thread...and it did help before that addition. No longer needed it seems and the OS seems to handle scheduling without hints just fine.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14685 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Michael Sevakis 2007-09-13 21:40:56 +00:00
parent 5128080328
commit 4117c64917

View file

@ -225,17 +225,10 @@ void thread_sdl_unlock(void)
void switch_thread(bool save_context, struct thread_entry **blocked_list)
{
static int counter = 0;
struct thread_entry *current = running;
SDL_UnlockMutex(m);
if (counter++ >= 50)
{
SDL_Delay(0);
counter = 0;
}
/* Any other thread waiting already will get it first */
SDL_LockMutex(m);
running = current;