Function: get_memcpy_desc_size
Applicability
Product |
Supported |
|---|---|
Atlas 350 Accelerator Card |
√ |
√ |
|
√ |
|
x |
|
x |
|
√ |
Description
Obtains the memory size used by the memory copy descriptor of the current device.
This API needs to work with other key APIs to implement memory copy. For details, see acl.rt.memcpy_async_with_desc.
Prototype
- C Prototype
1aclError aclrtGetMemcpyDescSize(aclrtMemcpyKind kind, size_t *descSize)
- Python Function
1desc_size, ret = acl.rt.get_memcpy_desc_size(kind)
Parameters
Parameter |
Description |
|---|---|
kind |
Int, memory copy type. Currently, only ACL_MEMCPY_INNER_DEVICE_TO_DEVICE is supported, indicating memory copy within a device. |
Return Value
Return Value |
Description |
|---|---|
desc_size |
Int, memory size, in bytes. |
ret |
Int, error code. 0 on success; else, failure. |
Parent topic: Memory Management