Helper method to check if allocation is compressed

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
Bartosz Dunajski
2021-12-01 18:11:27 +00:00
committed by Compute-Runtime-Automation
parent 7b55d38e34
commit 55959d4d1d
15 changed files with 32 additions and 94 deletions

View File

@@ -68,7 +68,7 @@ SurfaceInfo *getDumpSurfaceInfo(GraphicsAllocation &gfxAllocation, DumpFormat du
surfaceInfo->format = gmm->gmmResourceInfo->getResourceFormatSurfaceState();
surfaceInfo->tilingType = gmm->gmmResourceInfo->getTileModeSurfaceState();
surfaceInfo->surftype = getImageSurfaceTypeFromGmmResourceType<GfxFamily>(gmm->gmmResourceInfo->getResourceType());
surfaceInfo->compressed = gmm->isCompressionEnabled;
surfaceInfo->compressed = gfxAllocation.isCompressionEnabled();
surfaceInfo->dumpType = (AubAllocDump::DumpFormat::IMAGE_TRE == dumpFormat) ? dumpType::tre : dumpType::bmp;
}
@@ -163,7 +163,7 @@ template <typename GfxFamily>
void dumpImageInTreFormat(GraphicsAllocation &gfxAllocation, AubMemDump::AubFileStream *stream, uint32_t context) {
using RENDER_SURFACE_STATE = typename GfxFamily::RENDER_SURFACE_STATE;
auto gmm = gfxAllocation.getDefaultGmm();
if ((gmm->gmmResourceInfo->getNumSamples() > 1) || (gmm->isCompressionEnabled)) {
if ((gmm->gmmResourceInfo->getNumSamples() > 1) || (gfxAllocation.isCompressionEnabled())) {
DEBUG_BREAK_IF(true); //unsupported
return;
}