MxbsMemset
Function Usage
This function is used to configure memory.
You are advised to use MxbsMemset preferentially because Memset is the same as a system function name.
Prototype
1 2 | static APP_ERROR MemoryHelper::MxbsMemset(MemoryData& data, int32_t value, size_t count); static APP_ERROR MemoryHelper::MxbsMemset(MemoryData& data, int32_t value, size_t count, AscendStream &stream); |
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
data |
Input |
Memory data to be configured. The value range of data.size is [1, 4294967296]. |
value |
Input |
Value to be configured. |
count |
Input |
Length of the data to be configured. The length cannot be greater than the actual memory length. Otherwise, a core dump may occur. |
stream |
Input |
AscendStream type. When the value is AscendStream::DefaultStream(), the API performs a synchronous operation. In other cases, the API performs asynchronous operations. |
Response Parameters
Data Structure |
Description |
|---|---|
APP_ERROR |
For details about the returned error codes, see APP_ERROR Description. |
Parent topic: MemoryHelper