[vlc-devel] [PATCH] thread: change posix thread priorities to 0

Rémi Denis-Courmont remi at remlab.net
Mon Apr 6 10:02:09 CEST 2020


Le lauantaina 4. huhtikuuta 2020, 4.13.45 EEST Marvin Scholz a écrit :
> Makes it clearer that those have no effect anymore now.

IMO, we should remove the priority parameter as François implied.

If somebody really has a demonstrated use of priorities, they can use their 
OS-specific call or vlc_set_priority().

> ---
>  include/vlc_threads.h | 11 +++++++----
>  1 file changed, 7 insertions(+), 4 deletions(-)
> 
> diff --git a/include/vlc_threads.h b/include/vlc_threads.h
> index 1da9f941f7..d94882a17a 100644
> --- a/include/vlc_threads.h
> +++ b/include/vlc_threads.h
> @@ -221,12 +221,15 @@ typedef pthread_key_t   vlc_threadvar_t;
>   */
>  typedef struct vlc_timer *vlc_timer_t;
> 
> +/* Thread priorities.
> + * No effect for POSIX threads
> + */
>  # define VLC_THREAD_PRIORITY_LOW      0
> -# define VLC_THREAD_PRIORITY_INPUT   10
> -# define VLC_THREAD_PRIORITY_AUDIO    5
> +# define VLC_THREAD_PRIORITY_INPUT    0
> +# define VLC_THREAD_PRIORITY_AUDIO    0
>  # define VLC_THREAD_PRIORITY_VIDEO    0
> -# define VLC_THREAD_PRIORITY_OUTPUT  15
> -# define VLC_THREAD_PRIORITY_HIGHEST 20
> +# define VLC_THREAD_PRIORITY_OUTPUT   0
> +# define VLC_THREAD_PRIORITY_HIGHEST  0
> 
>  #endif


-- 
Rémi Denis-Courmont
Tapiola new town, Uusimaan Republic





More information about the vlc-devel mailing list