Table of Contents

Name

qthread_id - returns the qthread’s unique ID number

Synopsis

#include <qthread.h>

unsigned int
qthread_id (void);

Description

This function returns the unique identifier associated with the qthread me. This is used mostly for debugging, as obtaining a global identifier requires synchronization. Unless otherwise configured, the qthread library assigns thread ids only when they are asked for. Generally they are monotonically increasing values, but the value can wrap around after UINT_MAX threads.

Return Value

On success, the thread’s identifying number is returned.

See Also

qthread_retloc(3) , qthread_shep(3) , qthread_stackleft(3)


Table of Contents