Add instance of gmm helper to execution environment

Change-Id: I1b044611fbad91fbb681ba233938f41502f29056
This commit is contained in:
Mateusz Jablonski
2018-07-03 10:00:12 +02:00
committed by sys_ocldev
parent f26535a93d
commit 94dbdb602d
67 changed files with 220 additions and 204 deletions

View File

@@ -24,6 +24,9 @@
#include "runtime/gmm_helper/gmm_helper.h"
namespace OCLRT {
GmmMemoryBase::GmmMemoryBase() {
clientContext = GmmHelper::gmmClientContext;
}
bool GmmMemoryBase::configureDeviceAddressSpace(GMM_ESCAPE_HANDLE hAdapter,
GMM_ESCAPE_HANDLE hDevice,
GMM_ESCAPE_FUNC_TYPE pfnEscape,
@@ -33,7 +36,7 @@ bool GmmMemoryBase::configureDeviceAddressSpace(GMM_ESCAPE_HANDLE hAdapter,
BOOLEAN BDWL3Coherency,
GMM_GFX_SIZE_T SizeOverride,
GMM_GFX_SIZE_T SlmGfxSpaceReserve) {
return GmmHelper::gmmClientContext->ConfigureDeviceAddressSpace(
return clientContext->ConfigureDeviceAddressSpace(
{hAdapter},
{hDevice},
{pfnEscape},
@@ -46,7 +49,7 @@ bool GmmMemoryBase::configureDeviceAddressSpace(GMM_ESCAPE_HANDLE hAdapter,
}
uintptr_t GmmMemoryBase::getInternalGpuVaRangeLimit() {
return static_cast<uintptr_t>(GmmHelper::gmmClientContext->GetInternalGpuVaRangeLimit());
return static_cast<uintptr_t>(clientContext->GetInternalGpuVaRangeLimit());
}
}; // namespace OCLRT