From 01c73b561f6b554afc1acc598d255cb8aa2c3b90 Mon Sep 17 00:00:00 2001 From: Satyanvesh Dittakavi Date: Wed, 30 Oct 2024 15:47:28 +0000 Subject: [PATCH] SWDEV-491967 - Add the right VGPRs per SIMD and VGPR Granularity for gfx12 - Default values are being assigned causing occupancy calculation to go wrong without the right values defined for gfx12 ASICs - Also added the these values for gfx1105 Change-Id: I611cc3a8ed8c57f2def637310ce1c3a48c16a574 [ROCm/clr commit: a26dc29eb96c7ae8ba01f6b96690350c92825496] --- projects/clr/rocclr/device/rocm/rocdevice.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/projects/clr/rocclr/device/rocm/rocdevice.cpp b/projects/clr/rocclr/device/rocm/rocdevice.cpp index 75687e7554..648b63f83a 100644 --- a/projects/clr/rocclr/device/rocm/rocdevice.cpp +++ b/projects/clr/rocclr/device/rocm/rocdevice.cpp @@ -1806,11 +1806,24 @@ bool Device::populateOCLDeviceConstants() { HIP_MEM_POOL_USE_VM &= info_.virtualMemoryManagement_; switch (isa().versionMajor()) { + case (12): + if (isa().versionMinor() == 0) { + switch (isa().versionStepping()) { + case (0): + case (1): + default: + info_.vgprAllocGranularity_ = 24; + info_.vgprsPerSimd_ = 1536; + break; + } + } + break; case (11): if (isa().versionMinor() == 0) { switch (isa().versionStepping()) { case (0): case (1): + case (5): info_.vgprAllocGranularity_ = 24; info_.vgprsPerSimd_ = 1536; break;