AllocMutexID (ISASI)
Applicability
Product |
Supported |
|---|---|
Atlas 350 Accelerator Card |
√ |
x |
|
x |
|
x |
|
x |
|
x |
|
x |
Function Usage
Obtains and occupies a mutex ID from the framework. It is used together with ReleaseMutexID. It manages the obtaining and release of mutex IDs. An obtained mutex ID can be passed to the Mutex::Lock/Unlock API. In this case, Mutex::Lock/Unlock can be used together with other APIs such as TQue.
Prototype
1 | __aicore__ inline MutexID AllocMutexID() |
Parameters
None
Returns
Mutex ID. Each ID indicates a mutex lock. The type is defined as follows:
1 | using MutexID = uint8_t; |
Constraints
The number of mutex IDs is limited. After using a mutex ID, call ReleaseMutexID immediately to release it, preventing mutex ID exhaustion.