Posts one or more threads of an event completion.
Standard C library (libc.a)
#include <sys/thread.h>
int thread_post_many( nthreads, tidp, erridp)
int nthreads;
tid_t * tidp;
tid_t * erridp;
The thread_post_many subroutine posts one or more threads of the occurrence of the event. The number of threads to be posted is specified by the value of the nthreads parameter, while the tidp parameter points to an array of thread IDs of threads that need to be posted. The subroutine works just like the thread_post subroutine but can be used to post to multiple threads at the same time.
A maximum of 512 threads can be posted in one call to the thread_post_many subroutine.
An optional address to a thread ID field may be passed in the erridp parameter. This field is normally ignored by the kernel unless the subroutine fails because the calling process has no permissions to post to any one of the specified threads. In this case, the kernel posts all threads in the array pointed at by the tidp parameter up to the first failing thread and fills the erridp parameter with the failing thread's ID.
On successful completion, the thread_post_many subroutine returns a value of 0. If unsuccessful, a value of -1 is returned and the global variable errno is set to indicate the error.
The thread_post_many subroutine is unsuccessful when one of the
following is true:
The thread_wait (thread_wait Subroutine) subroutine, and thread_post (thread_post Subroutine) subroutine.