Implement cooperative threads on hosted platforms using C code.
commitc5dc63ed1248eeb2c6c4de05f9b1a0381a3182f2
authorkugel <kugel@a1c6a512-1295-4272-9138-f99709370657>
Fri, 18 Feb 2011 22:46:01 +0000 (18 22:46 +0000)
committerkugel <kugel@a1c6a512-1295-4272-9138-f99709370657>
Fri, 18 Feb 2011 22:46:01 +0000 (18 22:46 +0000)
treeff86c384a574ac20d3418c1b904ed4d0de1f6980
parentc406eb80f830ab3fb285f5e6816fd43304b9fbb2
Implement cooperative threads on hosted platforms using C code.

This replaces SDL threads with real cooperative threads, which are less cpu intensive and allow priority scheduling.
The backend for context switching is dependant on the host (sigaltstack/longjmp on Unix, Fibers on Windows).
configure has options to force or disallow SDL threads.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29327 a1c6a512-1295-4272-9138-f99709370657
13 files changed:
firmware/SOURCES
firmware/export/config.h
firmware/export/thread.h
firmware/target/hosted/sdl/kernel-sdl.c
firmware/target/hosted/sdl/system-sdl.c
firmware/target/hosted/sdl/system-sdl.h
firmware/target/hosted/sdl/thread-sdl.h
firmware/target/hosted/thread-arm.c [moved from firmware/target/hosted/android/thread-android-arm.c with 95% similarity]
firmware/target/hosted/thread-unix.c [new file with mode: 0644]
firmware/target/hosted/thread-win32.c [new file with mode: 0644]
firmware/thread.c
tools/configure
uisimulator/common/io.c