performance: Change preferred allocation method to AllocateByKmd

Related-To: NEO-7194
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2023-07-24 11:39:59 +00:00
committed by Compute-Runtime-Automation
parent 94b69aae80
commit 957aa99f9e
2 changed files with 3 additions and 3 deletions

View File

@@ -9,7 +9,7 @@
namespace NEO {
const GfxMemoryAllocationMethod preferredAllocationMethod = GfxMemoryAllocationMethod::UseUmdSystemPtr;
const GfxMemoryAllocationMethod preferredAllocationMethod = GfxMemoryAllocationMethod::AllocateByKmd;
size_t WddmMemoryManager::getHugeGfxMemoryChunkSize(GfxMemoryAllocationMethod allocationMethod) const {
return 4 * MemoryConstants::gigaByte - MemoryConstants::pageSize64k;

View File

@@ -237,7 +237,7 @@ TEST_F(WddmMemoryManagerAllocPathTests, givenAllocateGraphicsMemoryUsingKmdAndMa
allocData.makeGPUVaDifferentThanCPUPtr = true;
auto graphicsAllocation = memoryManager->allocateGraphicsMemoryUsingKmdAndMapItToCpuVA(allocData, false);
if (preferredAllocationMethod == GfxMemoryAllocationMethod::AllocateByKmd) {
if (preferredAllocationMethod == GfxMemoryAllocationMethod::AllocateByKmd && is64bit) {
EXPECT_FALSE(memoryManager->mapGpuVirtualAddressWithCpuPtr);
} else {
EXPECT_TRUE(memoryManager->mapGpuVirtualAddressWithCpuPtr);
@@ -494,7 +494,7 @@ TEST_F(WddmMemoryManagerTests, givenTypeWhenCallIsStatelessAccessRequiredThenPro
TEST_F(WddmMemoryManagerTests, givenForcePreferredAllocationMethodFlagSetWhenGettingPreferredAllocationMethodThenValueFlagIsReturned) {
DebugManagerStateRestore restorer;
EXPECT_EQ(preferredAllocationMethod, MockWddmMemoryManager::getPreferredAllocationMethod());
EXPECT_EQ(GfxMemoryAllocationMethod::AllocateByKmd, MockWddmMemoryManager::getPreferredAllocationMethod());
for (const auto &allocationMethod : {GfxMemoryAllocationMethod::UseUmdSystemPtr, GfxMemoryAllocationMethod::AllocateByKmd}) {
DebugManager.flags.ForcePreferredAllocationMethod.set(static_cast<int32_t>(allocationMethod));