1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-18 12:55:16 +00:00
mpv/osdep
wm4 fa929eb0d0 win32: pthread: avoid using TLS, simplify pthread_t
Don't use __thread, which requires heavy runtime in some cases (such as
MinGW-w64, at least under some configurations, forcing you to link to
its pthread runtime DLL).

The pthread_t struct was needed over a simple thread ID, because
pthread_join() needed to access some sort of context from pthread_t.
Further, pthread_exit() and pthread_detach() need the context of the
current thread, for which we relied on TLS.

Replace these uses by a global thread array. This includes all threads
created by the thread wrapper. Hopefully the number of threads created
by mpv is low (say, below 20), and threads are not that often created or
destroyed. So just keeping them in an array with linear search lookup
should be reasonable.
2017-06-15 16:33:42 +02:00
..
android Initial Android support 2016-02-10 21:29:36 +01:00
ar Fix misspellings 2016-06-26 13:47:21 +02:00
win32 win32: pthread: avoid using TLS, simplify pthread_t 2017-06-15 16:33:42 +02:00
atomic.h atomic: remove __atomic builtin usage 2017-02-13 06:45:40 +01:00
compiler.h osdep/compiler.h: change license to LGPL 2017-05-08 13:11:46 +02:00
endian.h audio: drop swapped-endian audio formats 2014-09-23 23:09:25 +02:00
glob-win.c glob-win: relicense to LGPL 2016-02-18 22:57:28 +11:00
io.c win32: fix mismatched free/talloc_free 2017-04-12 14:12:41 +02:00
io.h win32: add UTF-8 getcwd() wrapper 2017-04-11 12:19:41 +02:00
macosx_application_objc.h osx: initial Touch Bar support 2017-03-26 20:26:18 +02:00
macosx_application.h build: move main-fn files to osdep 2015-05-02 18:59:58 +02:00
macosx_application.m osx: fix Touch Bar access on systems without Touch Bar support 2017-04-02 21:02:33 +02:00
macosx_compat.h osx: fix key input in certain circumstances 2017-03-26 20:38:26 +02:00
macosx_events_objc.h osx: fix key input in certain circumstances 2017-03-26 20:38:26 +02:00
macosx_events.h osx: fix key input in certain circumstances 2017-03-26 20:38:26 +02:00
macosx_events.m osx: fix deadlock on exit with libmpv on OSX 2017-04-19 12:55:44 +02:00
macosx_touchbar.h osx: initial Touch Bar support 2017-03-26 20:26:18 +02:00
macosx_touchbar.m osx: initial Touch Bar support 2017-03-26 20:26:18 +02:00
macosx_versions.h osx: drop support for OS X 10.7 and earlier 2017-02-27 23:53:53 +01:00
main-fn-cocoa.c build: move main-fn files to osdep 2015-05-02 18:59:58 +02:00
main-fn-unix.c build: move main-fn files to osdep 2015-05-02 18:59:58 +02:00
main-fn-win.c player: do not let pseudo-gui override user config settings 2016-09-23 21:24:50 +02:00
main-fn.h build: move main-fn files to osdep 2015-05-02 18:59:58 +02:00
mpv.exe.manifest win32: add Windows 10 compatibility GUID 2015-12-20 21:06:02 +11:00
mpv.rc mpv.rc, mpv.exe.manifest: change license to LGPL 2017-06-12 17:06:03 +02:00
path-macosx.m Relicense some non-MPlayer source files to LGPL 2.1 or later 2016-01-19 18:36:06 +01:00
path-unix.c Relicense some non-MPlayer source files to LGPL 2.1 or later 2016-01-19 18:36:06 +01:00
path-win.c win32: build with -DINITGUID 2016-09-28 21:38:52 +10:00
path.h path: update path descriptions 2015-05-02 16:14:51 +02:00
semaphore_osx.c Fix use of ISC license 2017-04-15 16:20:00 +02:00
semaphore.h osdep: hack to fix build with low quality pthreads-w32 headers 2014-09-20 04:18:40 +02:00
strnlen.h Initial Android support 2016-02-10 21:29:36 +01:00
subprocess-posix.c Relicense some non-MPlayer source files to LGPL 2.1 or later 2016-01-19 18:36:06 +01:00
subprocess-win.c osdep: rename atomics.h to atomic.h 2016-09-07 11:26:25 +02:00
subprocess.c subprocess: add a callback to ignore output 2016-07-05 19:15:59 +02:00
subprocess.h subprocess: add a callback to ignore output 2016-07-05 19:15:59 +02:00
terminal-unix.c terminal: change license to LGPL 2017-06-14 14:28:05 +02:00
terminal-win.c terminal: change license to LGPL 2017-06-14 14:28:05 +02:00
terminal.h terminal: change license to LGPL 2017-06-14 14:28:05 +02:00
threads.c win32: pthread: use the new thread naming API 2017-05-18 00:11:14 +10:00
threads.h threads: use utility+POSIX functions instead of weird wrappers 2015-05-11 23:44:36 +02:00
timer-darwin.c
timer-linux.c osdep/timer*: change license to LGPL 2017-05-05 12:35:57 +02:00
timer-win2.c osdep/timer*: change license to LGPL 2017-05-05 12:35:57 +02:00
timer.c Relicense some non-MPlayer source files to LGPL 2.1 or later 2016-01-19 18:36:06 +01:00
timer.h osdep/timer*: change license to LGPL 2017-05-05 12:35:57 +02:00
w32_keyboard.c Revert "win32: add mappings for some special keys" 2015-06-24 15:14:38 +02:00
w32_keyboard.h w32: use the w32_common keymap in terminal-win too 2014-01-19 14:42:15 +01:00
win32-console-wrapper.c win32: fix some Clang warnings 2016-11-17 23:34:20 +11:00
windows_utils.c vo_opengl: angle: rewrite with custom swap chain 2017-02-07 22:45:07 +11:00
windows_utils.h win32: add COM-specific SAFE_RELEASE to windows_utils.h 2017-01-30 00:22:30 +11:00