pthread_curcpu_np(3) netbsd man page | unix.com

Man Page: pthread_curcpu_np

Operating Environment: netbsd

Section: 3

PTHREAD_CURCPU_NP(3)					   BSD Library Functions Manual 				      PTHREAD_CURCPU_NP(3)

NAME
pthread_curcpu_np -- get current CPU identifier
SYNOPSIS
#include <pthread.h> unsigned int pthread_curcpu_np(void);
DESCRIPTION
The pthread_curcpu_np() function provides a way for a thread to know which CPU it's currently running on. Note that, unless the thread is bound to a specific CPU, the result might be already stale when the function returns. However, it still can be useful as a hint to achieve better CPU locality.
RETURN VALUES
The pthread_curcpu_np() function returns the integer identifier of the CPU which is currently running the calling thread.
COMPATIBILITY
The pthread_curcpu_np() function is a non-standard extension.
SEE ALSO
affinity(3), pthread(3)
BSD
November 10, 2011 BSD
Related Man Pages
pthread_attr_getaffinity_np(3) - suse
cpuset_set(3) - netbsd
cpuset_zero(3) - netbsd
pthread_setaffinity_np(3) - netbsd
cpu_get_current(3) - osf1
Similar Topics in the Unix Linux Community
Unix File Permissions
Vm versus physical linux server
RFC - Korn shell prompt
BSD Unix Toolbox: 1000+ Commands for FreeBSD, OpenBSD, and NetBSD
Grep command to show the number of results