From 45f9fa1a555da43748b613682121df61349d7a5a Mon Sep 17 00:00:00 2001 From: Prike Liang Date: Fri, 25 Mar 2022 14:33:14 +0800 Subject: [PATCH] kfdtest: decrease granularityMB for handling small vram system It's not possible to allocate the 3/4 vram size with granularityMB being 128 when vram size < 512MB and decrease granularityMB to 16 has no significant impact on ROCt test on other system. So let's decrease granularityMB on small vram system for handling LargestVramBufferTest(). Change-Id: Iea7c29abfd382a20761b653730fd09a220ad2fd0 Signed-off-by: Prike Liang [ROCm/ROCR-Runtime commit: 6c103877dd6d0d8dbe383ae7e58d18f2e0a04d54] --- projects/rocr-runtime/tests/kfdtest/src/KFDMemoryTest.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/rocr-runtime/tests/kfdtest/src/KFDMemoryTest.cpp b/projects/rocr-runtime/tests/kfdtest/src/KFDMemoryTest.cpp index 31f199f79f..8cf24ffb1b 100644 --- a/projects/rocr-runtime/tests/kfdtest/src/KFDMemoryTest.cpp +++ b/projects/rocr-runtime/tests/kfdtest/src/KFDMemoryTest.cpp @@ -965,7 +965,7 @@ void KFDMemoryTest::BinarySearchLargestBuffer(int allocNode, const HsaMemFlags & int ret; HsaMemMapFlags mapFlags = {0}; - HSAuint64 granularityMB = 128; + HSAuint64 granularityMB = highMB > 512 ? 128 : 16; /* Testing big buffers in VRAM */ unsigned int * pDb = NULL;