Debug mask support to force uncached Gmm usage type

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
Bartosz Dunajski
2022-05-18 11:22:39 +00:00
committed by Compute-Runtime-Automation
parent 5f38555af5
commit 56a164ffcd
4 changed files with 27 additions and 1 deletions

View File

@@ -15,6 +15,12 @@
namespace NEO {
GMM_RESOURCE_USAGE_TYPE_ENUM CacheSettingsHelper::getGmmUsageType(AllocationType allocationType, bool forceUncached, const HardwareInfo &hwInfo) {
if (DebugManager.flags.ForceUncachedGmmUsageType.get()) {
if ((1llu << (static_cast<int64_t>(allocationType) - 1)) & DebugManager.flags.ForceUncachedGmmUsageType.get()) {
forceUncached = true;
}
}
if (forceUncached || DebugManager.flags.ForceAllResourcesUncached.get()) {
return getDefaultUsageTypeWithCachingDisabled(allocationType);
} else {