Files
compute-runtime/unit_tests/gen10/windows/os_interface_tests_gen10.cpp
Artur Harasimiuk 40146291ad Update copyright headers
Updating files modified in 2018 only. Older files remain with old style
copyright header

Change-Id: Ic99f2e190ad74b4b7f2bd79dd7b9fa5fbe36ec92
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2018-09-20 18:02:35 +02:00

33 lines
1.0 KiB
C++

/*
* Copyright (C) 2017-2018 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#include "runtime/execution_environment/execution_environment.h"
#include "unit_tests/os_interface/windows/os_interface_win_tests.h"
#include "unit_tests/gen_common/test.h"
typedef OsInterfaceTest OsInterfaceTestCnl;
GEN10TEST_F(OsInterfaceTestCnl, askKmdIfPreemptionRegisterWhitelisted) {
HardwareInfo *hwInfo = nullptr;
const HardwareInfo *refHwinfo = *platformDevices;
size_t numDevices = 0;
ExecutionEnvironment executionEnvironment;
bool success = DeviceFactory::getDevices(&hwInfo, numDevices, executionEnvironment);
EXPECT_TRUE(success);
for (size_t i = 0u; i < numDevices; i++) {
if (hwInfo[i].pWaTable->waEnablePreemptionGranularityControlByUMD) {
EXPECT_TRUE(hwInfo[i].capabilityTable.whitelistedRegisters.csChicken1_0x2580);
} else {
EXPECT_FALSE(hwInfo[i].capabilityTable.whitelistedRegisters.csChicken1_0x2580);
}
}
DeviceFactory::releaseDevices();
}