pthread_attr_init() | Initializes a thread attributes object. |
pthread_attr_destroy() | Destroys a thread attributes object. |
pthread_attr_setdetachstate() | Sets the detachstate attribute of a thread attributes object. This attribute determines if a thread created with this thread attributes object is in a detached state or not. |
pthread_attr_getdetachstate() | Gets the detach state attribute from a thread attributes object. |
pthread_attr_setstackaddr() | Sets the value of the stackaddr attribute of a thread attributes object. This attribute specifies the stack address of a thread created with this attributes object. |
pthread_attr_getstackaddr() | Gets the stackaddr attribute from a thread attributes object. |
pthread_attr_setstacksize() | Sets the value of the stacksize attribute of a thread attributes object. This attribute specifies the minimum stack size, in bytes, of a thread created with this thread attributes object. |
pthread_attr_getstacksize() | Gets the stacksize attribute from a thread attributes object. |
pthread_testcancel() | Creates a cancellation point in the calling thread. |
pthread_setcancelstate() | Atomically sets the calling thread’s cancelability state to the indicated state and returns the previous cancelability state at a specified location reference. |
pthread_setcanceltype() | Atomically sets the calling thread’s cancelability type to the indicated type and returns the previous cancelability type at a specified location reference. |
pthread_create() | Creates a new thread and initializes its attributes using the thread attributes object specified, or standard values instead, if the NULL pointer is specified. After thread creation, a thread attributes object can be reused to create another thread, or deleted. |
pthread_exit() | Terminates the calling thread safely, and stores a termination status for any thread that may join the calling thread. |
pthread_cancel() | Requests the cancellation of the specified thread. The action depends on the cancelability of the target thread. |
pthread_kill() | Sends the specified signal to the specified thread. It acts with threads like the kill subroutine with single-threaded processes. |
pthread_join() | Blocks the calling thread until the specified thread terminates. If the specified thread is in a detached state (non-joinable), an error is returned. |
pthread_detach() | Used to indicate to the implementation that storage for the specified thread can be reclaimed when that thread terminates. |
pthread_once() | Executes the specified routine exactly once in a process. The first call to this subroutine by any thread in the process executes the given routine, without parameters. Any subsequent call will have no effect. |
pthread_self() | Returns the calling thread’s ID. |
pthread_equal() | Compares the two specified thread IDs. Returns zero if and only if the IDs are equal. |
pthread_atfork() | Threads can fork processes. This routine registers fork cleanup handlers. Three handlers can be specified: prepare, parent, and child. The prepare handler is called before the processing of the fork subroutine commences. The parent handler is called after the processing of the fork subroutine completes in the parent process. The child handler is called after the processing of the fork subroutine completes in the child process. |
pthread_cleanup_push() | Pushes the specified cancellation cleanup handler routine onto the calling thread’s cancellation cleanup stack. |
pthread_cleanup_pop() | Removes the routine at the top of the calling thread’s cancellation cleanup stack and optionally invokes it (if execute is non-zero). |