diff --git a/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp b/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp index 904f18820c..fed1771593 100644 --- a/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp +++ b/rocclr/runtime/device/gpu/gslbe/src/rt/GSLDevice.cpp @@ -207,6 +207,10 @@ CALGSLDevice::open(uint32 gpuIndex, bool enableHighPerformanceState, bool report m_dcfg.syncObjectMode.value = (GPU_USE_SYNC_OBJECTS) ? GSL_CONFIG_SYNCOBJECT_MODE_ON : GSL_CONFIG_SYNCOBJECT_MODE_OFF; + // Use OCL_SET_SVM_SIZE to set SVM size we need + m_dcfg.ndevSVMSize.hasValue = true; + m_dcfg.ndevSVMSize.value = OCL_SET_SVM_SIZE; + // Use GPU_IFH_MODE to test with IFH mode enabled m_dcfg.DropFlush.hasValue = true; m_dcfg.DropFlush.value = (GPU_IFH_MODE == 1); diff --git a/rocclr/runtime/utils/flags.hpp b/rocclr/runtime/utils/flags.hpp index 413c313083..7836a79d8a 100644 --- a/rocclr/runtime/utils/flags.hpp +++ b/rocclr/runtime/utils/flags.hpp @@ -170,6 +170,8 @@ release(int, AMD_GPU_FORCE_SINGLE_FP_DENORM, -1, \ "Force denorm for single precision: -1 - don't force, 0 - disable, 1 - enable") \ debug(bool, OCL_FORCE_CPU_SVM, false, \ "force svm support for CPU") \ +debug(uint, OCL_SET_SVM_SIZE, 4096, \ + "set SVM space size for discrete GPU") \ debug(uint, OCL_SYSMEM_REQUIREMENT, 2, \ "Use flag to change the minimum requirement of system memory not to downgrade") \ debug(bool, GPU_ENABLE_HW_DEBUG, false, \