fix: treat tiled 1D images as 2D with height 1 for BLT copies

Related-To: NEO-14147, HSD-14024424096, HSD-14024424178
Signed-off-by: Maciej Plewka <maciej.plewka@intel.com>
This commit is contained in:
Maciej Plewka
2025-03-05 15:33:02 +00:00
committed by Compute-Runtime-Automation
parent 9eb8e1812c
commit a93cecac36
2 changed files with 80 additions and 2 deletions

View File

@@ -84,9 +84,10 @@ void BlitCommandsHelper<GfxFamily>::appendSurfaceType(const BlitProperties &blit
auto resInfo = blitProperties.srcAllocation->getDefaultGmm()->gmmResourceInfo.get();
auto resourceType = resInfo->getResourceType();
auto isArray = resInfo->getArraySize() > 1;
auto isTiled = resInfo->getResourceFlags()->Info.Tile4 || resInfo->getResourceFlags()->Info.Tile64;
if (resourceType == GMM_RESOURCE_TYPE::RESOURCE_1D) {
if (isArray) {
if (isArray || isTiled) {
blitCmd.setSourceSurfaceType(XY_BLOCK_COPY_BLT::SURFACE_TYPE::SURFACE_TYPE_SURFTYPE_2D);
} else {
blitCmd.setSourceSurfaceType(XY_BLOCK_COPY_BLT::SURFACE_TYPE::SURFACE_TYPE_SURFTYPE_1D);
@@ -103,9 +104,10 @@ void BlitCommandsHelper<GfxFamily>::appendSurfaceType(const BlitProperties &blit
auto resInfo = blitProperties.dstAllocation->getDefaultGmm()->gmmResourceInfo.get();
auto resourceType = resInfo->getResourceType();
auto isArray = resInfo->getArraySize() > 1;
auto isTiled = resInfo->getResourceFlags()->Info.Tile4 || resInfo->getResourceFlags()->Info.Tile64;
if (resourceType == GMM_RESOURCE_TYPE::RESOURCE_1D) {
if (isArray) {
if (isArray || isTiled) {
blitCmd.setDestinationSurfaceType(XY_BLOCK_COPY_BLT::SURFACE_TYPE::SURFACE_TYPE_SURFTYPE_2D);
} else {
blitCmd.setDestinationSurfaceType(XY_BLOCK_COPY_BLT::SURFACE_TYPE::SURFACE_TYPE_SURFTYPE_1D);