upipe-pthread/upipe_pthread_transfer.h header reference
Upipe module allowing to transfer other pipes to a new POSIX thread More
Header inclusion
Members
Function
- struct upipe_mgr * upipe_pthread_xfer_mgr_alloc(uint8_t queue_length, uint16_t msg_pool_depth, struct uprobe *uprobe_pthread_upump_mgr, upump_mgr_alloc upump_mgr_alloc, uint16_t upump_pool_depth, uint16_t upump_blocker_pool_depth, struct umutex *mutex, pthread_t *pthread_id_p, const pthread_attr_t *attr)
Description
This is particularly helpful for multithreaded applications.
Members detail
This macro is declared in upipe-pthread/upipe_pthread_transfer.h source file, line 32.
struct upipe_mgr * upipe_pthread_xfer_mgr_alloc(uint8_t queue_length, uint16_t msg_pool_depth, struct uprobe *uprobe_pthread_upump_mgr, upump_mgr_alloc upump_mgr_alloc, uint16_t upump_pool_depth, uint16_t upump_blocker_pool_depth, struct umutex *mutex, pthread_t *pthread_id_p, const pthread_attr_t *attr)
This function is declared in upipe-pthread/upipe_pthread_transfer.h source file, line 68.
This function returns a management structure for transfer pipes, using a new pthread. You would need one management structure per target thread.
Parameter list:
- queue_length: maximum length of the internal queue of commands
- msg_pool_depth: maximum number of messages in the pool
- uprobe_pthread_upump_mgr: pointer to optional probe, that will be set with the created upump_mgr
- upump_mgr_alloc: alloc function provided by the upump manager
- upump_pool_depth: maximum number of upump structures in the pool
- upump_blocker_pool_depth: maximum number of upump_blocker structures in the pool
- mutex: mutual exclusion pimitives to access the event loop, or NULL
- pthread_id_p: reference to created thread ID (may be NULL)
- attr: pthread attributes
The return value is pointer to xfer manager