aclrtMallocAttrValue
typedef union {
uint16_t moduleId;
uint32_t deviceId;
uint32_t vaFlag;
uint8_t rsv[8];
} aclrtMallocAttrValue;
Member |
Description |
|---|---|
moduleId |
Module ID. You are advised to set this parameter to 33, indicating the application. In this situation, the memory is allocated by the user application, which facilitates fault locating in maintenance and debugging scenarios. |
deviceId |
Device ID. If the device ID configured here is different from the device ID used for compute, an error is reported. You are advised not to set this parameter. |
vaFlag |
Whether to use the virtual address (VA) consistency function when the host memory is allocated by using the aclrtMallocHostWithCfg call.
Only some product models support the VA consistency function. For those not supporting this function, an error is reported when this function is used. The following product models support this function: |
rsv |
Reserved. The value is fixed at 0. |