libuv 1.45.0, #include cleanup, probably something else.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4308 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
40
deps/libuv/docs/src/threading.rst
vendored
40
deps/libuv/docs/src/threading.rst
vendored
@ -88,6 +88,46 @@ Threads
|
||||
|
||||
.. versionadded:: 1.26.0
|
||||
|
||||
.. c:function:: int uv_thread_setaffinity(uv_thread_t* tid, char* cpumask, char* oldmask, size_t mask_size)
|
||||
|
||||
Sets the specified thread's affinity to cpumask, which is specified in
|
||||
bytes. Optionally returning the previous affinity setting in oldmask.
|
||||
On Unix, uses :man:`pthread_getaffinity_np(3)` to get the affinity setting
|
||||
and maps the cpu_set_t to bytes in oldmask. Then maps the bytes in cpumask
|
||||
to a cpu_set_t and uses :man:`pthread_setaffinity_np(3)`. On Windows, maps
|
||||
the bytes in cpumask to a bitmask and uses SetThreadAffinityMask() which
|
||||
returns the previous affinity setting.
|
||||
|
||||
The mask_size specifies the number of entries (bytes) in cpumask / oldmask,
|
||||
and must be greater-than-or-equal-to :c:func:`uv_cpumask_size`.
|
||||
|
||||
.. note::
|
||||
Thread affinity setting is not atomic on Windows. Unsupported on macOS.
|
||||
|
||||
.. versionadded:: 1.45.0
|
||||
|
||||
.. c:function:: int uv_thread_getaffinity(uv_thread_t* tid, char* cpumask, size_t mask_size)
|
||||
|
||||
Gets the specified thread's affinity setting. On Unix, this maps the
|
||||
cpu_set_t returned by :man:`pthread_getaffinity_np(3)` to bytes in cpumask.
|
||||
|
||||
The mask_size specifies the number of entries (bytes) in cpumask,
|
||||
and must be greater-than-or-equal-to :c:func:`uv_cpumask_size`.
|
||||
|
||||
.. note::
|
||||
Thread affinity getting is not atomic on Windows. Unsupported on macOS.
|
||||
|
||||
.. versionadded:: 1.45.0
|
||||
|
||||
.. c:function:: int uv_thread_getcpu(void)
|
||||
|
||||
Gets the CPU number on which the calling thread is running.
|
||||
|
||||
.. note::
|
||||
Currently only implemented on Windows, Linux and FreeBSD.
|
||||
|
||||
.. versionadded:: 1.45.0
|
||||
|
||||
.. c:function:: uv_thread_t uv_thread_self(void)
|
||||
.. c:function:: int uv_thread_join(uv_thread_t *tid)
|
||||
.. c:function:: int uv_thread_equal(const uv_thread_t* t1, const uv_thread_t* t2)
|
||||
|
Reference in New Issue
Block a user