HcommBatchModeEnd
Applicability
Product |
Supported |
|---|---|
Atlas 350 Accelerator Card |
√ |
√ |
|
√ |
|
x |
|
x |
|
x |
For
Function
Submits and triggers the execution of all operations cached in batch mode. All data plane API call operations between HcommBatchModeStart and HcommBatchModeEnd will be executed collectively at this point.
Prototype
1 | int32_t HcommBatchModeEnd(const char *batchTag) |
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
batchTag |
Input |
Batch task identifier, which must be the same batchTag passed to HcommBatchModeStart. |
Returns
int32_t: 0 on success; else, failure.
Restrictions
HcommBatchModeStart and HcommBatchModeEnd must be called in pairs and executed in the same thread.
Only the Atlas 350 Accelerator Card supports both batch mode and immediate execution mode (without calling batch APIs). Other products must use batch mode.
Example
1 2 3 4 5 6 7 8 9 | char *tag = ""; // Start the batch mode (a temporary batch task). HcommBatchModeStart(tag); // In batch mode, calls to data plane APIs are not executed immediately. // ... // End the batch mode and trigger execution. HcommBatchModeEnd(tag); |