SWDEV-541478 - return hipSuccess for hipTexObjectCreate TypePitch2D with zero width or height (#712)

Esse commit está contido em:
Todd tiantuo Li
2025-09-19 20:48:01 -07:00
commit de GitHub
commit 7137c7f3d8
+5
Ver Arquivo
@@ -1491,6 +1491,11 @@ hipError_t hipTexObjectCreate(hipTextureObject_t* pTexObject, const HIP_RESOURCE
HIP_RETURN(hipErrorInvalidValue);
}
if (static_cast<hipResourceType>(pResDesc->resType) == hipResourceTypePitch2D &&
((pResDesc->res.pitch2D.width == 0) || (pResDesc->res.pitch2D.height == 0))) {
HIP_RETURN(hipSuccess);
}
hipResourceDesc resDesc = hip::getResourceDesc(*pResDesc);
hipTextureDesc texDesc = hip::getTextureDesc(*pTexDesc);