Add debug flag to override gpu address space

Change-Id: Ifce09cf2b0f1935ce15f1a718cff36b0c44848ca
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:
Dunajski, Bartosz
2019-12-17 13:34:05 +01:00
committed by sys_ocldev
parent 559c67aa7c
commit 73697b7ab4
4 changed files with 17 additions and 0 deletions

View File

@@ -84,6 +84,16 @@ TEST_F(PlatformTest, getDevices) {
EXPECT_NE(nullptr, allDevices);
}
TEST_F(PlatformTest, givenDebugFlagSetWhenInitializingPlatformThenOverrideGpuAddressSpace) {
DebugManagerStateRestore restore;
DebugManager.flags.OverrideGpuAddressSpace.set(12);
bool status = pPlatform->initialize();
EXPECT_TRUE(status);
EXPECT_EQ(maxNBitValue(12), pPlatform->peekExecutionEnvironment()->getHardwareInfo()->capabilityTable.gpuAddressSpace);
}
TEST_F(PlatformTest, PlatformgetAsCompilerEnabledExtensionsString) {
std::string compilerExtensions = pPlatform->peekCompilerExtensions();
EXPECT_EQ(std::string(""), compilerExtensions);