Grf configuration

Change-Id: I3741f53a38c6707b0c8ad82ae553ea65ae6917e4
Signed-off-by: Pawel Wilma <pawel.wilma@intel.com>
This commit is contained in:
Pawel Wilma
2018-09-21 14:06:35 +02:00
committed by sys_ocldev
parent a81b1a461f
commit e06aa17dfc
19 changed files with 73 additions and 26 deletions

View File

@@ -8,6 +8,7 @@
#pragma once
#include "runtime/helpers/string.h"
#include "runtime/kernel/grf_config.h"
#include "runtime/kernel/kernel.h"
#include "runtime/scheduler/scheduler_kernel.h"
#include "runtime/device/device.h"
@@ -118,6 +119,7 @@ class MockKernel : public Kernel {
SPatchExecutionEnvironment *executionEnvironment = new SPatchExecutionEnvironment;
memset(executionEnvironment, 0, sizeof(SPatchExecutionEnvironment));
executionEnvironment->HasDeviceEnqueue = 0;
executionEnvironment->NumGRFRequired = GrfConfig::DefaultGrfNumber;
info->patchInfo.executionEnvironment = executionEnvironment;
info->crossThreadData = new char[crossThreadSize];
@@ -243,6 +245,8 @@ class MockKernelWithInternals {
memset(&executionEnvironment, 0, sizeof(SPatchExecutionEnvironment));
memset(&executionEnvironmentBlock, 0, sizeof(SPatchExecutionEnvironment));
memset(&dataParameterStream, 0, sizeof(SPatchDataParameterStream));
executionEnvironment.NumGRFRequired = GrfConfig::DefaultGrfNumber;
executionEnvironmentBlock.NumGRFRequired = GrfConfig::DefaultGrfNumber;
kernelHeader.SurfaceStateHeapSize = sizeof(sshLocal);
threadPayload.LocalIDXPresent = 1;
threadPayload.LocalIDYPresent = 1;
@@ -324,6 +328,7 @@ class MockParentKernel : public Kernel {
SPatchExecutionEnvironment *executionEnvironment = new SPatchExecutionEnvironment;
*executionEnvironment = {};
executionEnvironment->HasDeviceEnqueue = 1;
executionEnvironment->NumGRFRequired = GrfConfig::DefaultGrfNumber;
info->patchInfo.executionEnvironment = executionEnvironment;
SPatchAllocateStatelessDefaultDeviceQueueSurface *allocateDeviceQueue = new SPatchAllocateStatelessDefaultDeviceQueueSurface;