SWDEV-256810 : hipMemcpy2D API handle width, src/dst pitch 0

Change-Id: I4f60b220624f4235c0c3daf68adcd5a496e93696
Tá an tiomantas seo le fáil i:
agodavar
2020-11-02 11:45:03 -05:00
tiomanta ag Anusha Godavarthy Surya
tuismitheoir 4c1f86699d
tiomantas 77e5c4110e
+6
Féach ar an gComhad
@@ -1511,6 +1511,12 @@ hipError_t ihipMemcpyParam2D(const hip_Memcpy2D* pCopy,
hipError_t ihipMemcpy2D(void* dst, size_t dpitch, const void* src, size_t spitch, size_t width,
size_t height, hipMemcpyKind kind, hipStream_t stream, bool isAsync = false) {
hip_Memcpy2D desc = {};
if (spitch == 0 || dpitch == 0) {
return hipErrorUnknown;
}
if (width == 0) {
return hipSuccess;
}
desc.srcXInBytes = 0;
desc.srcY = 0;