mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 23:03:02 +08:00
performance: add debug key to control cpu cacheablitiy
Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
f7888fac0d
commit
0e29ab8387
@@ -136,4 +136,19 @@ HWTEST_F(GmmTests, givenVariousResourceUsageTypeWhenCreateGmmThenFlagCacheableIs
|
||||
}
|
||||
}
|
||||
|
||||
HWTEST_F(GmmTests, givenVariousCacheableDebugSettingsTheCacheableFieldIsProgrammedCorrectly) {
|
||||
DebugManagerStateRestore restore;
|
||||
debugManager.flags.OverrideGmmCacheableField.set(0);
|
||||
StorageInfo storageInfo{};
|
||||
GmmRequirements gmmRequirements{};
|
||||
|
||||
auto gmm = std::make_unique<Gmm>(getGmmHelper(), nullptr, 0, 0, GMM_RESOURCE_USAGE_OCL_SYSTEM_MEMORY_BUFFER, storageInfo, gmmRequirements);
|
||||
EXPECT_FALSE(gmm->resourceParams.Flags.Info.Cacheable);
|
||||
|
||||
debugManager.flags.OverrideGmmCacheableField.set(1);
|
||||
|
||||
auto gmm2 = std::make_unique<Gmm>(getGmmHelper(), nullptr, 0, 0, GMM_RESOURCE_USAGE_OCL_SYSTEM_MEMORY_BUFFER, storageInfo, gmmRequirements);
|
||||
EXPECT_TRUE(gmm2->resourceParams.Flags.Info.Cacheable);
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
Reference in New Issue
Block a user