2.2 (revision 4737)
Functions
OTF2_Pthread_Locks.h File Reference

Pthread locks for OTF2. More...

#include <otf2/otf2.h>
#include <pthread.h>

Go to the source code of this file.

Functions

static OTF2_ErrorCode OTF2_Pthread_Archive_SetLockingCallbacks (OTF2_Archive *archive, const pthread_mutexattr_t *mutexAttribute)
 Register callbacks to use Pthread mutexes for a OTF2 archive. More...
 
static OTF2_ErrorCode OTF2_Pthread_Reader_SetLockingCallbacks (OTF2_Reader *reader, const pthread_mutexattr_t *mutexAttribute)
 Register callbacks to use Pthread mutexes for a OTF2 reader. More...
 

Detailed Description

Pthread locks for OTF2.

Function Documentation

static OTF2_ErrorCode OTF2_Pthread_Archive_SetLockingCallbacks ( OTF2_Archive archive,
const pthread_mutexattr_t *  mutexAttribute 
)
static

Register callbacks to use Pthread mutexes for a OTF2 archive.

Parameters
archiveThe archive handle.
mutexAttributeA possible pthread_mutexattr_t which will be used in all pthread_mutex_init calls. A corresponding pthread_mutexattr_destroy call is done when the archive will be closed. But no such call will be issued, if a call to this function will fail.
Since
Version 1.5
Returns
Success or error code.
Examples:
otf2_pthread_writer_example.c.
static OTF2_ErrorCode OTF2_Pthread_Reader_SetLockingCallbacks ( OTF2_Reader reader,
const pthread_mutexattr_t *  mutexAttribute 
)
static

Register callbacks to use Pthread mutexes for a OTF2 reader.

Parameters
readerThe reader handle.
mutexAttributeA possible pthread_mutexattr_t which will e used in all pthread_mutex_init calls. A corresponding pthread_mutexattr_destroy call is done when the reader will be closed. But no such call will be issued, if a call to this function will fail.
Since
Version 1.5
Returns
Success or error code.