2 .\" Copyright (c) 2009 Michael Kerrisk, <mtk.manpages@gmail.com>
4 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
6 .TH pthread_yield 3 (date) "Linux man-pages (unreleased)"
8 pthread_yield \- yield the processor
11 .RI ( libpthread ", " \-lpthread )
14 .BR "#define _GNU_SOURCE" " /* See feature_test_macros(7) */"
15 .B #include <pthread.h>
17 .B [[deprecated]] int pthread_yield(void);
21 This function is deprecated; see below.
24 causes the calling thread to relinquish the CPU.
25 The thread is placed at the end of the run queue for its static
26 priority and another thread is scheduled to run.
27 For further details, see
33 on error, it returns an error number.
35 On Linux, this call always succeeds
36 (but portable and future-proof applications should nevertheless
37 handle a possible error return).
39 Since glibc 2.34, this function is marked as deprecated.
41 For an explanation of the terms used in this section, see
49 Interface Attribute Value
52 T} Thread safety MT-Safe
58 This call is nonstandard, but present on several other systems.
62 .\" e.g., the BSDs, Tru64, AIX, and Irix.
64 On Linux, this function is implemented as a call to
68 is intended for use with real-time scheduling policies (i.e.,
74 with nondeterministic scheduling policies such as
76 is unspecified and very likely means your application design is broken.
79 .\" FIXME . .BR pthread_cond_wait (3),