mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 07:14:10 +08:00
Move clGfxCoreHelper ownership to rootDeviceEnv
Related-To: NEO-6853 Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
5ff0ff0997
commit
468d722efb
@@ -15,9 +15,11 @@
|
||||
#include "shared/source/compiler_interface/default_cache_config.h"
|
||||
#include "shared/source/debugger/debugger.h"
|
||||
#include "shared/source/debugger/debugger_l0.h"
|
||||
#include "shared/source/device/device.h"
|
||||
#include "shared/source/execution_environment/execution_environment.h"
|
||||
#include "shared/source/gmm_helper/gmm_helper.h"
|
||||
#include "shared/source/gmm_helper/page_table_mngr.h"
|
||||
#include "shared/source/helpers/api_gfx_core_helper.h"
|
||||
#include "shared/source/helpers/api_specific_config.h"
|
||||
#include "shared/source/helpers/bindless_heaps_helper.h"
|
||||
#include "shared/source/helpers/compiler_hw_info_config.h"
|
||||
@@ -75,8 +77,9 @@ HardwareInfo *RootDeviceEnvironment::getMutableHardwareInfo() const {
|
||||
return hwInfo.get();
|
||||
}
|
||||
|
||||
void RootDeviceEnvironment::setHwInfo(const HardwareInfo *hwInfo) {
|
||||
void RootDeviceEnvironment::setHwInfoAndInitHelpers(const HardwareInfo *hwInfo) {
|
||||
*this->hwInfo = *hwInfo;
|
||||
initHelpers();
|
||||
}
|
||||
|
||||
bool RootDeviceEnvironment::isFullRangeSvm() const {
|
||||
@@ -149,6 +152,10 @@ CompilerInterface *RootDeviceEnvironment::getCompilerInterface() {
|
||||
return this->compilerInterface.get();
|
||||
}
|
||||
|
||||
void RootDeviceEnvironment::initHelpers() {
|
||||
initApiGfxCoreHelper();
|
||||
}
|
||||
|
||||
BuiltIns *RootDeviceEnvironment::getBuiltIns() {
|
||||
if (this->builtins.get() == nullptr) {
|
||||
std::lock_guard<std::mutex> autolock(this->mtx);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -33,6 +33,8 @@ class SipKernel;
|
||||
class SWTagsManager;
|
||||
class ProductHelper;
|
||||
class GfxCoreHelper;
|
||||
class ApiGfxCoreHelper;
|
||||
|
||||
struct HardwareInfo;
|
||||
|
||||
struct RootDeviceEnvironment {
|
||||
@@ -46,7 +48,7 @@ struct RootDeviceEnvironment {
|
||||
|
||||
MOCKABLE_VIRTUAL const HardwareInfo *getHardwareInfo() const;
|
||||
HardwareInfo *getMutableHardwareInfo() const;
|
||||
void setHwInfo(const HardwareInfo *hwInfo);
|
||||
void setHwInfoAndInitHelpers(const HardwareInfo *hwInfo);
|
||||
bool isFullRangeSvm() const;
|
||||
|
||||
MOCKABLE_VIRTUAL void initAubCenter(bool localMemoryEnabled, const std::string &aubFileName, CommandStreamReceiverType csrType);
|
||||
@@ -55,6 +57,7 @@ struct RootDeviceEnvironment {
|
||||
void initGmm();
|
||||
void initDebugger();
|
||||
void initDebuggerL0(Device *neoDevice);
|
||||
|
||||
MOCKABLE_VIRTUAL void prepareForCleanup() const;
|
||||
MOCKABLE_VIRTUAL bool initAilConfiguration();
|
||||
GmmHelper *getGmmHelper() const;
|
||||
@@ -65,10 +68,12 @@ struct RootDeviceEnvironment {
|
||||
void createBindlessHeapsHelper(MemoryManager *memoryManager, bool availableDevices, uint32_t rootDeviceIndex, DeviceBitfield deviceBitfield);
|
||||
void limitNumberOfCcs(uint32_t numberOfCcs);
|
||||
bool isNumberOfCcsLimited() const;
|
||||
const ProductHelper &getProductHelper() const;
|
||||
|
||||
void initHelpers();
|
||||
void initApiGfxCoreHelper();
|
||||
template <typename HelperType>
|
||||
HelperType &getHelper() const;
|
||||
const ProductHelper &getProductHelper() const;
|
||||
|
||||
std::unique_ptr<SipKernel> sipKernels[static_cast<uint32_t>(SipKernelType::COUNT)];
|
||||
std::unique_ptr<GmmHelper> gmmHelper;
|
||||
@@ -82,6 +87,7 @@ struct RootDeviceEnvironment {
|
||||
std::unique_ptr<BuiltIns> builtins;
|
||||
std::unique_ptr<Debugger> debugger;
|
||||
std::unique_ptr<SWTagsManager> tagsManager;
|
||||
std::unique_ptr<ApiGfxCoreHelper> apiGfxCoreHelper;
|
||||
ExecutionEnvironment &executionEnvironment;
|
||||
|
||||
AffinityMaskHelper deviceAffinityMask{true};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (C) 2019-2022 Intel Corporation
|
||||
# Copyright (C) 2019-2023 Intel Corporation
|
||||
#
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
@@ -12,6 +12,7 @@ set(NEO_CORE_HELPERS
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/addressing_mode_helper.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/affinity_mask.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/aligned_memory.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/api_gfx_core_helper.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/app_resource_defines.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/app_resource_helper.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/app_resource_helper.cpp
|
||||
|
||||
18
shared/source/helpers/api_gfx_core_helper.h
Normal file
18
shared/source/helpers/api_gfx_core_helper.h
Normal file
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* Copyright (C) 2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
namespace NEO {
|
||||
|
||||
class ApiGfxCoreHelper {
|
||||
public:
|
||||
ApiGfxCoreHelper() = default;
|
||||
virtual ~ApiGfxCoreHelper() = default;
|
||||
};
|
||||
|
||||
} // namespace NEO
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -54,6 +54,7 @@ bool DeviceFactory::prepareDeviceEnvironmentsForProductFamilyOverride(ExecutionE
|
||||
auto &rootDeviceEnvironment = *executionEnvironment.rootDeviceEnvironments[rootDeviceIndex].get();
|
||||
auto hardwareInfo = rootDeviceEnvironment.getMutableHardwareInfo();
|
||||
*hardwareInfo = *hwInfoConst;
|
||||
rootDeviceEnvironment.initHelpers();
|
||||
|
||||
if (hwInfoConfigStr == "default") {
|
||||
hwInfoConfig = defaultHardwareInfoConfigTable[hwInfoConst->platform.eProductFamily];
|
||||
|
||||
@@ -422,7 +422,7 @@ int Drm::setupHardwareInfo(const DeviceDescriptor *device, bool setupFeatureTabl
|
||||
auto deviceId = hwInfo->platform.usDeviceID;
|
||||
auto revisionId = hwInfo->platform.usRevId;
|
||||
|
||||
rootDeviceEnvironment.setHwInfo(device->pHwInfo);
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(device->pHwInfo);
|
||||
|
||||
hwInfo->platform.usDeviceID = deviceId;
|
||||
hwInfo->platform.usRevId = revisionId;
|
||||
|
||||
@@ -101,6 +101,8 @@ bool Wddm::init() {
|
||||
|
||||
auto &productHelper = rootDeviceEnvironment.getHelper<ProductHelper>();
|
||||
productHelper.adjustPlatformForProductFamily(hardwareInfo);
|
||||
rootDeviceEnvironment.initHelpers();
|
||||
|
||||
if (productHelper.configureHwInfoWddm(hardwareInfo, hardwareInfo, rootDeviceEnvironment)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ class MemoryAllocatorFixture : public MemoryManagementFixture {
|
||||
MemoryManagementFixture::setUp();
|
||||
executionEnvironment = new ExecutionEnvironment();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
device.reset(MockDevice::createWithExecutionEnvironment<MockDevice>(defaultHwInfo.get(), executionEnvironment, 0u));
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -18,7 +18,7 @@ using namespace NEO;
|
||||
|
||||
void MemoryManagerWithCsrFixture::setUp() {
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->initGmm();
|
||||
csr = std::make_unique<MockCommandStreamReceiver>(this->executionEnvironment, 0, 1);
|
||||
memoryManager = new MockMemoryManager(executionEnvironment);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -43,7 +43,7 @@ bool prepareDeviceEnvironments(ExecutionEnvironment &executionEnvironment) {
|
||||
}
|
||||
auto currentHwInfo = executionEnvironment.rootDeviceEnvironments[0]->getHardwareInfo();
|
||||
if (currentHwInfo->platform.eProductFamily == IGFX_UNKNOWN && currentHwInfo->platform.eRenderCoreFamily == IGFX_UNKNOWN_CORE) {
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
|
||||
if (ultHwConfig.useMockedPrepareDeviceEnvironmentsFunc) {
|
||||
@@ -66,7 +66,7 @@ bool prepareDeviceEnvironment(ExecutionEnvironment &executionEnvironment, std::s
|
||||
executionEnvironment.prepareRootDeviceEnvironment(rootDeviceIndex);
|
||||
auto currentHwInfo = executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->getHardwareInfo();
|
||||
if (currentHwInfo->platform.eProductFamily == IGFX_UNKNOWN && currentHwInfo->platform.eRenderCoreFamily == IGFX_UNKNOWN_CORE) {
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
if (ultHwConfig.useMockedPrepareDeviceEnvironmentsFunc) {
|
||||
uint32_t numRootDevices = DebugManager.flags.CreateMultipleRootDevices.get() != 0 ? DebugManager.flags.CreateMultipleRootDevices.get() : 1u;
|
||||
|
||||
@@ -322,7 +322,7 @@ class DrmMockEngine : public DrmMock {
|
||||
uint32_t queryEngineInfoSuccessCount = std::numeric_limits<uint32_t>::max();
|
||||
|
||||
DrmMockEngine(RootDeviceEnvironment &rootDeviceEnvironment) : DrmMock(rootDeviceEnvironment) {
|
||||
rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
|
||||
int handleRemainingRequests(DrmIoctl request, void *arg) override;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -197,7 +197,7 @@ std::unique_ptr<AubExecutionEnvironment> getEnvironment(bool createTagAllocation
|
||||
DeviceBitfield deviceBitfield(1);
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
uint32_t rootDeviceIndex = 0u;
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->aubCenter.reset(new AubCenter());
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@ MockDevice::MockDevice(ExecutionEnvironment *executionEnvironment, uint32_t root
|
||||
getRootDeviceEnvironmentRef().osTime = MockOSTime::create();
|
||||
}
|
||||
auto &hwInfo = getHardwareInfo();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
|
||||
initializeCaps();
|
||||
@@ -106,7 +106,7 @@ ExecutionEnvironment *MockDevice::prepareExecutionEnvironment(const HardwareInfo
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numRootDevices);
|
||||
pHwInfo = pHwInfo ? pHwInfo : defaultHwInfo.get();
|
||||
for (auto i = 0u; i < executionEnvironment->rootDeviceEnvironments.size(); i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(pHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(pHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
@@ -143,7 +143,7 @@ ExecutionEnvironment *MockDevice::prepareExecutionEnvironment(const HardwareInfo
|
||||
|
||||
auto hwInfo = pHwInfo ? pHwInfo : defaultHwInfo.get();
|
||||
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo);
|
||||
|
||||
MockAubCenterFixture::setMockAubCenter(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -119,7 +119,7 @@ class MockDevice : public RootDevice {
|
||||
template <typename T>
|
||||
static T *createWithExecutionEnvironment(const HardwareInfo *pHwInfo, ExecutionEnvironment *executionEnvironment, uint32_t rootDeviceIndex) {
|
||||
pHwInfo = pHwInfo ? pHwInfo : defaultHwInfo.get();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(pHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(pHwInfo);
|
||||
T *device = new T(executionEnvironment, rootDeviceIndex);
|
||||
return createDeviceInternals(device);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -36,9 +36,9 @@ MockExecutionEnvironment::MockExecutionEnvironment(const HardwareInfo *hwInfo, b
|
||||
rootDeviceEnvironments[rootDeviceIndex].reset(rootDeviceEnvironment);
|
||||
|
||||
if (hwInfo) {
|
||||
rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(hwInfo);
|
||||
rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(hwInfo);
|
||||
} else {
|
||||
rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
if (useMockGmm) {
|
||||
rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -60,7 +60,7 @@ void UltDeviceFactory::prepareDeviceEnvironments(ExecutionEnvironment &execution
|
||||
if (executionEnvironment.rootDeviceEnvironments[i]->getHardwareInfo() == nullptr ||
|
||||
(executionEnvironment.rootDeviceEnvironments[i]->getHardwareInfo()->platform.eProductFamily == IGFX_UNKNOWN &&
|
||||
executionEnvironment.rootDeviceEnvironments[i]->getHardwareInfo()->platform.eRenderCoreFamily == IGFX_UNKNOWN_CORE)) {
|
||||
executionEnvironment.rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
}
|
||||
executionEnvironment.parseAffinityMask();
|
||||
|
||||
@@ -135,7 +135,7 @@ class DrmCommandStreamEnhancedTemplate : public ::testing::Test {
|
||||
ASSERT_NE(nullptr, mm);
|
||||
executionEnvironment->memoryManager.reset(mm);
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1u);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
device.reset(MockDevice::create<MockDevice>(executionEnvironment, rootDeviceIndex));
|
||||
device->resetCommandStreamReceiver(csr);
|
||||
@@ -216,7 +216,7 @@ class DrmCommandStreamEnhancedWithFailingExecTemplate : public ::testing::Test {
|
||||
ASSERT_NE(nullptr, mm);
|
||||
executionEnvironment->memoryManager.reset(mm);
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1u);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
device.reset(MockDevice::create<MockDevice>(executionEnvironment, rootDeviceIndex));
|
||||
device->resetCommandStreamReceiver(csr);
|
||||
|
||||
@@ -22,7 +22,7 @@ extern std::vector<void *> mmapVector;
|
||||
|
||||
void DrmMemoryManagerBasic::SetUp() {
|
||||
for (auto i = 0u; i < numRootDevices; i++) {
|
||||
executionEnvironment.rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[i]->osInterface = std::make_unique<OSInterface>();
|
||||
auto drm = Drm::create(nullptr, *executionEnvironment.rootDeviceEnvironments[i]);
|
||||
executionEnvironment.rootDeviceEnvironments[i]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(drm));
|
||||
@@ -49,7 +49,7 @@ void DrmMemoryManagerFixture::setUp(DrmMockCustom *mock, bool localMemoryEnabled
|
||||
this->mock = mock;
|
||||
for (auto i = 0u; i < numRootDevices; i++) {
|
||||
auto rootDeviceEnvironment = executionEnvironment->rootDeviceEnvironments[i].get();
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->osInterface = std::make_unique<OSInterface>();
|
||||
rootDeviceEnvironment->osInterface->setDriverModel(std::unique_ptr<DriverModel>(new DrmMockCustom(*rootDeviceEnvironment)));
|
||||
rootDeviceEnvironment->memoryOperationsInterface = DrmMemoryOperationsHandler::create(*rootDeviceEnvironment->osInterface->getDriverModel()->as<Drm>(), i);
|
||||
@@ -128,7 +128,7 @@ void DrmMemoryManagerFixtureWithoutQuietIoctlExpectation::setUp(bool enableLocal
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numRootDevices);
|
||||
uint32_t i = 0;
|
||||
for (auto &rootDeviceEnvironment : executionEnvironment->rootDeviceEnvironments) {
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->osInterface = std::make_unique<OSInterface>();
|
||||
rootDeviceEnvironment->osInterface->setDriverModel(std::unique_ptr<DriverModel>(new DrmMockCustom(*rootDeviceEnvironment)));
|
||||
rootDeviceEnvironment->memoryOperationsInterface = DrmMemoryOperationsHandler::create(*rootDeviceEnvironment->osInterface->getDriverModel()->as<Drm>(), i);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -25,7 +25,7 @@ class DrmMemoryManagerLocalMemoryPrelimTest : public ::testing::Test {
|
||||
|
||||
executionEnvironment = new ExecutionEnvironment();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]);
|
||||
auto memoryInfo = new MockExtendedMemoryInfo(*mock);
|
||||
@@ -64,7 +64,7 @@ class DrmMemoryManagerLocalMemoryWithCustomPrelimMockTest : public ::testing::Te
|
||||
const bool localMemoryEnabled = true;
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
mock = new DrmMockCustomPrelim(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -32,7 +32,7 @@ Drm **pDrmToReturnFromCreateFunc = nullptr;
|
||||
bool disableBindDefaultInTests = true;
|
||||
|
||||
Drm *Drm::create(std::unique_ptr<HwDeviceIdDrm> &&hwDeviceId, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
if (pDrmToReturnFromCreateFunc) {
|
||||
return *pDrmToReturnFromCreateFunc;
|
||||
}
|
||||
|
||||
@@ -175,7 +175,7 @@ TEST_F(CommandContainerTest, givenEnabledLocalMemoryAndIsaInSystemMemoryWhenCmdC
|
||||
auto executionEnvironment = new NEO::ExecutionEnvironment();
|
||||
const size_t numDevices = 1;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numDevices);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto hwInfo = executionEnvironment->rootDeviceEnvironments[0]->getMutableHardwareInfo();
|
||||
@@ -199,7 +199,7 @@ TEST_F(CommandContainerTest, givenForceDefaultHeapSizeWhenCmdContainerIsInitiali
|
||||
auto executionEnvironment = new NEO::ExecutionEnvironment();
|
||||
const size_t numDevices = 1;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numDevices);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto device = std::unique_ptr<MockDevice>(Device::create<MockDevice>(executionEnvironment, 0u));
|
||||
@@ -661,7 +661,7 @@ TEST_P(CommandContainerHeaps, givenCommandContainerForDifferentRootDevicesThenHe
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numDevices);
|
||||
for (auto i = 0u; i < numDevices; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
@@ -691,7 +691,7 @@ TEST_F(CommandContainerHeaps, givenCommandContainerForDifferentRootDevicesThenCm
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numDevices);
|
||||
for (auto i = 0u; i < numDevices; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
@@ -716,7 +716,7 @@ TEST_F(CommandContainerHeaps, givenCommandContainerForDifferentRootDevicesThenIn
|
||||
const size_t numDevices = 2;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numDevices);
|
||||
for (auto i = 0u; i < numDevices; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -33,7 +33,7 @@ HWTEST_F(AubCsrTest, givenLocalMemoryEnabledWhenGettingAddressSpaceForRingDataTy
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
uint32_t rootDeviceIndex = 0u;
|
||||
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->aubCenter.reset(new AubCenter());
|
||||
|
||||
@@ -67,7 +67,7 @@ HWTEST_F(AubCsrTest, givenAUBDumpForceAllToLocalMemoryWhenGettingAddressSpaceFor
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
uint32_t rootDeviceIndex = 0u;
|
||||
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->aubCenter.reset(new AubCenter());
|
||||
|
||||
@@ -99,7 +99,7 @@ HWTEST_F(AubCsrTest, WhenWriteWithAubManagerIsCalledThenAubManagerIsInvokedWithC
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
uint32_t rootDeviceIndex = 0u;
|
||||
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->aubCenter.reset(new AubCenter());
|
||||
|
||||
@@ -584,7 +584,7 @@ HWTEST_F(SimulatedCsrTest, givenAubCsrTypeWhenCreateCommandStreamReceiverThenPro
|
||||
|
||||
auto rootDeviceEnvironment = new MockRootDeviceEnvironment(executionEnvironment);
|
||||
executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex].reset(rootDeviceEnvironment);
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
EXPECT_EQ(nullptr, executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex]->aubCenter.get());
|
||||
EXPECT_FALSE(rootDeviceEnvironment->initAubCenterCalled);
|
||||
|
||||
@@ -31,7 +31,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryAndAllocationWithStorageIn
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -50,7 +50,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryAndNonLocalMemoryAllocatio
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -66,7 +66,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryAndAllocationWithStorageIn
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -85,7 +85,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryAndNonLocalMemoryAllocatio
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -104,7 +104,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryNoncloneableAllocationWith
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -128,7 +128,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryCloneableAllocationWithMan
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -152,7 +152,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryNoncloneableAllocationWith
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -177,7 +177,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryAndAllocationWithStorageIn
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
MemoryAllocation allocation(0, AllocationType::UNKNOWN, nullptr, reinterpret_cast<void *>(0x1000), 0x1000u,
|
||||
@@ -199,7 +199,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryWhenSimulatedCsrGetAddress
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
std::array<uint32_t, 6> localMemoryHints = {AubMemDump::DataTypeHintValues::TraceLogicalRingContextRcs,
|
||||
@@ -227,7 +227,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenLocalMemoryDisabledWhenSimulatedCsrGe
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = false;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
std::array<uint32_t, 7> nonLocalMemoryHints = {AubMemDump::DataTypeHintValues::TraceNotype,
|
||||
@@ -252,7 +252,7 @@ HWTEST_F(CommandStreamSimulatedTests, givenAUBDumpForceAllToLocalMemoryWhenSimul
|
||||
hardwareInfo.featureTable.flags.ftrLocalMemory = false;
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&hardwareInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hardwareInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
std::array<uint32_t, 7> localMemoryHints = {AubMemDump::DataTypeHintValues::TraceNotype,
|
||||
|
||||
@@ -442,7 +442,7 @@ HWTEST_F(SimulatedCsrTest, givenHwWithAubDumpCsrTypeWhenCreateCommandStreamRecei
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
auto rootDeviceEnvironment = static_cast<MockRootDeviceEnvironment *>(executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex].get());
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
EXPECT_EQ(nullptr, executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex]->aubCenter.get());
|
||||
EXPECT_FALSE(rootDeviceEnvironment->initAubCenterCalled);
|
||||
@@ -458,7 +458,7 @@ HWTEST_F(SimulatedCsrTest, givenTbxWithAubDumpCsrTypeWhenCreateCommandStreamRece
|
||||
|
||||
auto rootDeviceEnvironment = new MockRootDeviceEnvironment(executionEnvironment);
|
||||
executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex].reset(rootDeviceEnvironment);
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
EXPECT_EQ(nullptr, executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex]->aubCenter.get());
|
||||
EXPECT_FALSE(rootDeviceEnvironment->initAubCenterCalled);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -80,7 +80,7 @@ struct ComputeModeRequirements : public ::testing::Test {
|
||||
template <typename FamilyType>
|
||||
void setUpImpl(const NEO::HardwareInfo *hardwareInfo) {
|
||||
device.reset(MockDevice::createWithNewExecutionEnvironment<MockDevice>(hardwareInfo));
|
||||
device->executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hardwareInfo);
|
||||
device->executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hardwareInfo);
|
||||
device->executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
csr = new myCsr<FamilyType>(*device->executionEnvironment, device->getDeviceBitfield());
|
||||
|
||||
|
||||
@@ -591,7 +591,7 @@ HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenItIsQueriedForPreferredTagPoolSiz
|
||||
|
||||
HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpThenFileNameIsExtendedWithSystemInfo) {
|
||||
MockExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
executionEnvironment.initGmm();
|
||||
|
||||
@@ -606,7 +606,7 @@ HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpThenFileNameIsE
|
||||
|
||||
HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpThenOpenIsCalledOnAubManagerToOpenFileStream) {
|
||||
MockExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
std::unique_ptr<TbxCommandStreamReceiverHw<FamilyType>> tbxCsrWithAubDump(reinterpret_cast<TbxCommandStreamReceiverHw<FamilyType> *>(
|
||||
@@ -623,7 +623,7 @@ HWTEST_F(SimulatedCsrTest, givenTbxCsrTypeWhenCreateCommandStreamReceiverThenPro
|
||||
|
||||
auto rootDeviceEnvironment = new MockRootDeviceEnvironment(executionEnvironment);
|
||||
executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex].reset(rootDeviceEnvironment);
|
||||
rootDeviceEnvironment->setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
EXPECT_EQ(nullptr, executionEnvironment.rootDeviceEnvironments[expectedRootDeviceIndex]->aubCenter.get());
|
||||
EXPECT_FALSE(rootDeviceEnvironment->initAubCenterCalled);
|
||||
@@ -638,7 +638,7 @@ HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpInSubCaptureMod
|
||||
DebugManager.flags.AUBDumpSubCaptureMode.set(static_cast<int32_t>(AubSubCaptureManager::SubCaptureMode::Filter));
|
||||
|
||||
MockExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
std::unique_ptr<TbxCommandStreamReceiverHw<FamilyType>> tbxCsrWithAubDump(static_cast<TbxCommandStreamReceiverHw<FamilyType> *>(
|
||||
@@ -653,7 +653,7 @@ HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpInSubCaptureMod
|
||||
|
||||
HWTEST_F(TbxCommandStreamTests, givenTbxCsrWhenCreatedWithAubDumpSeveralTimesThenOpenIsCalledOnAubManagerOnceOnly) {
|
||||
MockExecutionEnvironment executionEnvironment(defaultHwInfo.get(), true, 1);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
|
||||
auto tbxCsrWithAubDump1 = std::unique_ptr<TbxCommandStreamReceiverHw<FamilyType>>(reinterpret_cast<TbxCommandStreamReceiverHw<FamilyType> *>(
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -29,7 +29,7 @@ struct L0DebuggerSharedLinuxFixture {
|
||||
auto executionEnvironment = new NEO::ExecutionEnvironment();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo ? hwInfo : defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo ? hwInfo : defaultHwInfo.get());
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
auto osInterface = new OSInterface();
|
||||
drmMock = new DrmMockResources(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -31,7 +31,7 @@ TEST(Debugger, givenL0DebuggerWhenGettingL0DebuggerThenCorrectObjectIsReturned)
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -50,7 +50,7 @@ TEST(Debugger, givenSourceLevelDebuggerWhenGettingL0DebuggerThenNullptrIsReturne
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -67,7 +67,7 @@ TEST(Debugger, givenL0DebuggerOFFWhenGettingStateSaveAreaHeaderThenValidSipTypeI
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
hwInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
|
||||
auto &gfxCoreHelper = executionEnvironment->rootDeviceEnvironments[0]->getHelper<GfxCoreHelper>();
|
||||
auto isHexadecimalArrayPreferred = gfxCoreHelper.isSipKernelAsHexadecimalArrayPreferred();
|
||||
@@ -105,7 +105,7 @@ TEST(Debugger, givenDebuggingEnabledInExecEnvWhenAllocatingIsaThenSingleBankIsUs
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
hwInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -133,7 +133,7 @@ TEST(Debugger, givenTileAttachAndDebuggingEnabledInExecEnvWhenAllocatingIsaThenM
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
hwInfo.featureTable.flags.ftrLocalMemory = true;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -157,7 +157,7 @@ TEST(Debugger, WhenInitializingDebuggerL0ThenCapabilitiesAreAdjustedAndDebuggerI
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -188,7 +188,7 @@ TEST(Debugger, GivenLegacyDebuggerWhenInitializingDebuggerL0ThenAbortIsCalledAft
|
||||
executionEnvironment->rootDeviceEnvironments[0]->debugger.reset(mockDebugger);
|
||||
|
||||
auto hwInfo = *NEO::defaultHwInfo.get();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
@@ -326,7 +326,7 @@ TEST(Debugger, givenNonLegacyDebuggerWhenInitializingDeviceCapsThenUnrecoverable
|
||||
auto mockBuiltIns = new NEO::MockBuiltins();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->builtins.reset(mockBuiltIns);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto debugger = new MockDebugger;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -45,7 +45,7 @@ TEST(EhlHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
HardwareInfo hwInfo = *defaultHwInfo;
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -49,7 +49,7 @@ TYPED_TEST_CASE(IcllpHwInfoTests, icllpTestTypes);
|
||||
TYPED_TEST(IcllpHwInfoTests, WhenGettingSystemInfoThenParamsAreValid) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DeviceDescriptor device = {0, &TypeParam::hwInfo, &TypeParam::setupHardwareInfo};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -52,7 +52,7 @@ TYPED_TEST(LkfHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
HardwareInfo hwInfo = *defaultHwInfo;
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -52,7 +52,7 @@ ADLNTEST_F(AdlnHwInfoLinux, WhenSettingUpHwInfoThenConfigIsCorrect) {
|
||||
HardwareInfo hwInfo = *defaultHwInfo;
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -66,7 +66,7 @@ TYPED_TEST_CASE(AdlpHwInfoLinux, adlpConfigTestTypes);
|
||||
TYPED_TEST(AdlpHwInfoLinux, givenAdlpConfigWhenSetupHardwareInfoThenGtSystemInfoAndWaAndFtrTablesAreSetCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -52,7 +52,7 @@ ADLSTEST_F(AdlsHwInfoLinux, WhenSettingUpHwInfoThenConfigIsCorrect) {
|
||||
HardwareInfo hwInfo = *defaultHwInfo;
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -76,7 +76,7 @@ TYPED_TEST_CASE(Dg1HwInfoLinux, dg1TestTypes);
|
||||
TYPED_TEST(Dg1HwInfoLinux, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -52,7 +52,7 @@ RKLTEST_F(RklHwInfoLinux, WhenSettingUpHwInfoThenConfigIsCorrect) {
|
||||
HardwareInfo hwInfo = *defaultHwInfo;
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -67,7 +67,7 @@ TYPED_TEST_CASE(TgllpHwInfoLinux, tgllpTestTypes);
|
||||
TYPED_TEST(TgllpHwInfoLinux, gtSetupIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 Intel Corporation
|
||||
* Copyright (C) 2019-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -75,7 +75,7 @@ GEN12LPTEST_F(Gen12LpGmmCallbacksTests, givenCcsEnabledhenWriteL3CalledThenSetRe
|
||||
localHwInfo.featureTable.flags.ftrCCSNode = true;
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1u);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
UltCommandStreamReceiver<FamilyType> csr(executionEnvironment, 0, 1);
|
||||
uint8_t buffer[128] = {};
|
||||
@@ -103,7 +103,7 @@ GEN12LPTEST_F(Gen12LpGmmCallbacksTests, givenCcsDisabledhenWriteL3CalledThenSetR
|
||||
localHwInfo.featureTable.flags.ftrCCSNode = false;
|
||||
ExecutionEnvironment executionEnvironment;
|
||||
executionEnvironment.prepareRootDeviceEnvironments(1u);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
executionEnvironment.initializeMemoryManager();
|
||||
UltCommandStreamReceiver<FamilyType> csr(executionEnvironment, 0, 1);
|
||||
uint8_t buffer[128] = {};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -90,7 +90,7 @@ TYPED_TEST_CASE(BdwHwInfoTests, bdwTestTypes);
|
||||
TYPED_TEST(BdwHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -145,7 +145,7 @@ TYPED_TEST_CASE(BxtHwInfoTests, bxtTestTypes);
|
||||
TYPED_TEST(BxtHwInfoTests, WhenConfiguringHwInfoThenConfigIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
DeviceDescriptor device = {0, &TypeParam::hwInfo, &TypeParam::setupHardwareInfo};
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -105,7 +105,7 @@ TYPED_TEST_CASE(CflHwInfoTests, cflTestTypes);
|
||||
TYPED_TEST(CflHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -157,7 +157,7 @@ TYPED_TEST_CASE(GlkHwInfoTests, glkTestTypes);
|
||||
TYPED_TEST(GlkHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -137,7 +137,7 @@ TYPED_TEST_CASE(KblHwInfoTests, kblTestTypes);
|
||||
TYPED_TEST(KblHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -167,7 +167,7 @@ TYPED_TEST_CASE(SklHwInfoTests, sklTestTypes);
|
||||
TYPED_TEST(SklHwInfoTests, WhenGtIsSetupThenGtSystemInfoIsCorrect) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -357,7 +357,7 @@ TEST(DrmBufferObject, givenDrmIoctlReturnsErrorNotSupportedThenBufferObjectRetur
|
||||
auto executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -384,7 +384,7 @@ TEST(DrmBufferObject, givenPerContextVmRequiredWhenBoBoundAndUnboundThenCorrectB
|
||||
auto executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -427,7 +427,7 @@ TEST(DrmBufferObject, givenPrintBOBindingResultWhenBOBindAndUnbindSucceedsThenPr
|
||||
auto executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -480,7 +480,7 @@ TEST(DrmBufferObject, givenPrintBOBindingResultWhenBOBindAndUnbindFailsThenPrint
|
||||
auto executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -63,7 +63,7 @@ HWTEST_F(DrmCommandStreamMMTest, givenForcePinDisabledWhenMemoryManagerIsCreated
|
||||
|
||||
MockExecutionEnvironment executionEnvironment;
|
||||
auto drm = new DrmMockCustom(*executionEnvironment.rootDeviceEnvironments[0]);
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
executionEnvironment.rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment.rootDeviceEnvironments[0]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(drm));
|
||||
@@ -82,7 +82,7 @@ HWTEST_F(DrmCommandStreamMMTest, givenExecutionEnvironmentWithMoreThanOneRootDev
|
||||
executionEnvironment.prepareRootDeviceEnvironments(2);
|
||||
|
||||
for (uint32_t rootDeviceIndex = 0; rootDeviceIndex < executionEnvironment.rootDeviceEnvironments.size(); rootDeviceIndex++) {
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment.rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
auto drm = new DrmMockCustom(*executionEnvironment.rootDeviceEnvironments[0]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -918,7 +918,7 @@ HWTEST_TEMPLATED_F(DrmCommandStreamBlitterDirectSubmissionTest, givenEnabledDire
|
||||
|
||||
HWTEST_TEMPLATED_F(DrmCommandStreamTest, givenDrmCommandStreamReceiverWhenCreatePageTableManagerIsCalledThenCreatePageTableManager) {
|
||||
executionEnvironment.prepareRootDeviceEnvironments(2);
|
||||
executionEnvironment.rootDeviceEnvironments[1]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[1]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment.rootDeviceEnvironments[1]->initGmm();
|
||||
executionEnvironment.rootDeviceEnvironments[1]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment.rootDeviceEnvironments[1]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(new DrmMockCustom(*executionEnvironment.rootDeviceEnvironments[0])));
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -394,14 +394,14 @@ struct DrmImplicitScalingCommandStreamTest : ::testing::Test {
|
||||
hwInfo.reset(new HardwareInfo(*defaultHwInfo));
|
||||
hwInfo->gtSystemInfo.MultiTileArchInfo.IsValid = true;
|
||||
hwInfo->gtSystemInfo.MultiTileArchInfo.TileCount = 0b11;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
constexpr int mockFd = 33;
|
||||
drm = new DrmMock(mockFd, *executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->setupIoctlHelper(hwInfo->platform.eProductFamily);
|
||||
drm->createVirtualMemoryAddressSpace(GfxCoreHelper::getSubDevicesCount(hwInfo.get()));
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(drm));
|
||||
executionEnvironment->rootDeviceEnvironments[0]->memoryOperationsInterface = DrmMemoryOperationsHandler::create(*drm, 0u);
|
||||
|
||||
@@ -51,7 +51,7 @@ struct DrmCommandStreamMultiTileMemExecFixture {
|
||||
*executionEnvironment);
|
||||
executionEnvironment->memoryManager.reset(memoryManager);
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1u);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(NEO::defaultHwInfo.get());
|
||||
executionEnvironment->initializeMemoryManager();
|
||||
|
||||
VariableBackup<UltHwConfig> backup(&ultHwConfig);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -196,7 +196,7 @@ TEST(DrmPrelimTest, givenContextDebugAvailableWhenCheckedForSupportThenTrueIsRet
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -220,7 +220,7 @@ TEST(DrmPrelimTest, givenContextDebugNotAvailableWhenCheckedForSupportThenTrueIs
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -315,7 +315,7 @@ TEST(DrmPrelimTest, givenProgramDebuggingAndContextDebugAvailableAndCCSEnginesWh
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -337,7 +337,7 @@ TEST(DrmPrelimTest, givenProgramDebuggingAndContextDebugAvailableAndCCSEnginesWh
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -215,7 +215,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, DrmTestXeHPAndLater, givenLinkBcsEngineWhenBindingS
|
||||
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
|
||||
@@ -244,7 +244,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, DrmTestXeHPAndLater, givenLinkBcsEngineWithoutMainC
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0;
|
||||
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
drm->supportedCopyEnginesMask.set(0, false);
|
||||
@@ -293,7 +293,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, DrmTestXeHPAndLater, giveNotAllLinkBcsEnginesWhenBi
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0;
|
||||
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
drm->supportedCopyEnginesMask.set(2, false);
|
||||
@@ -342,7 +342,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, DrmTestXeHPAndLater, givenLinkBcsEngineWhenBindingM
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0b1111;
|
||||
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
|
||||
@@ -373,7 +373,7 @@ HWTEST2_F(DrmTestXeHPCAndLater, givenBcsVirtualEnginesEnabledWhenCreatingContext
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileCount = 0;
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0;
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
drm->queryEngineInfo();
|
||||
@@ -402,7 +402,7 @@ HWTEST2_F(DrmTestXeHPCAndLater, givenBcsVirtualEnginesEnabledWhenCreatingContext
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileCount = 0;
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0;
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
drm->queryEngineInfo();
|
||||
@@ -431,7 +431,7 @@ HWTEST2_F(DrmTestXeHPCAndLater, givenBcsVirtualEnginesDisabledWhenCreatingContex
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileCount = 0;
|
||||
localHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0;
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&localHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&localHwInfo);
|
||||
auto drm = std::make_unique<DrmQueryMock>(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
ASSERT_NE(nullptr, drm);
|
||||
drm->supportedCopyEnginesMask = maxNBitValue(9);
|
||||
@@ -803,7 +803,7 @@ struct DistanceQueryDrmTests : ::testing::Test {
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
|
||||
rootDeviceEnvironment = executionEnvironment->rootDeviceEnvironments[0].get();
|
||||
rootDeviceEnvironment->setHwInfo(NEO::defaultHwInfo.get());
|
||||
rootDeviceEnvironment->setHwInfoAndInitHelpers(NEO::defaultHwInfo.get());
|
||||
}
|
||||
|
||||
std::unique_ptr<MyDrm> createDrm(bool supportDistanceInfoQuery) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -178,7 +178,7 @@ struct MultiTileMemoryInfoFixture : public ::testing::Test {
|
||||
void SetUp() override {
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
pHwInfo = executionEnvironment->rootDeviceEnvironments[0]->getHardwareInfo();
|
||||
|
||||
@@ -90,7 +90,7 @@ TEST_F(DrmMemoryManagerLocalMemoryPrelimTest, givenMultiRootDeviceEnvironmentAnd
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
auto mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
@@ -140,7 +140,7 @@ TEST_F(DrmMemoryManagerLocalMemoryPrelimTest, givenMultiRootDeviceEnvironmentAnd
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
auto mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
@@ -180,7 +180,7 @@ TEST_F(DrmMemoryManagerLocalMemoryPrelimTest, givenMultiRootDeviceEnvironmentAnd
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
auto mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
@@ -220,7 +220,7 @@ TEST_F(DrmMemoryManagerUsmSharedHandlePrelimTest, givenMultiRootDeviceEnvironmen
|
||||
auto osInterface = executionEnvironment->rootDeviceEnvironments[0]->osInterface.release();
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->initGmm();
|
||||
auto mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]);
|
||||
|
||||
@@ -255,7 +255,7 @@ TEST_F(DrmMemoryManagerLocalMemoryPrelimTest, givenMultiRootDeviceEnvironmentAnd
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
auto mock = new DrmQueryMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
@@ -2357,7 +2357,7 @@ using AllocationInfoLogging = DrmMemoryManagerLocalMemoryPrelimTest;
|
||||
TEST(AllocationInfoLogging, givenDrmGraphicsAllocationWithMultipleBOsWhenGettingImplementationSpecificAllocationInfoThenReturnInfoStringWithAllHandles) {
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmQueryMock drm{*executionEnvironment->rootDeviceEnvironments[0]};
|
||||
|
||||
@@ -61,7 +61,7 @@ class DrmMemoryManagerLocalMemoryTest : public ::testing::Test {
|
||||
const bool localMemoryEnabled = true;
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]);
|
||||
mock->memoryInfo.reset(new MockMemoryInfo(*mock));
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -88,7 +88,7 @@ class DrmMemoryManagerLocalMemoryWithCustomMockTest : public ::testing::Test {
|
||||
const bool localMemoryEnabled = true;
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
mock = new DrmMockCustom(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(mock));
|
||||
@@ -146,7 +146,7 @@ HWTEST2_F(DrmMemoryManagerLocalMemoryTest, givenMultiRootDeviceEnvironmentAndMem
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
std::vector<MemoryRegion> regionInfo(2);
|
||||
@@ -192,7 +192,7 @@ TEST_F(DrmMemoryManagerLocalMemoryTest, givenMultiRootDeviceEnvironmentAndMemory
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
std::vector<MemoryRegion> regionInfo(2);
|
||||
@@ -252,7 +252,7 @@ TEST_F(DrmMemoryManagerUsmSharedHandleTest, givenMultiRootDeviceEnvironmentAndMe
|
||||
auto osInterface = executionEnvironment->rootDeviceEnvironments[0]->osInterface.release();
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]);
|
||||
|
||||
std::vector<MemoryRegion> regionInfo(2);
|
||||
@@ -288,7 +288,7 @@ TEST_F(DrmMemoryManagerLocalMemoryTest, givenMultiRootDeviceEnvironmentAndNoMemo
|
||||
|
||||
executionEnvironment->prepareRootDeviceEnvironments(rootDevicesNumber);
|
||||
for (uint32_t i = 0; i < rootDevicesNumber; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[i]);
|
||||
|
||||
mock->memoryInfo.reset(nullptr);
|
||||
@@ -460,7 +460,7 @@ class DrmMemoryManagerLocalMemoryMemoryBankTest : public ::testing::Test {
|
||||
const bool localMemoryEnabled = true;
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
mock = new DrmTipMock(*executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]);
|
||||
mock->memoryInfo.reset(new MockMemoryInfo(*mock));
|
||||
executionEnvironment->rootDeviceEnvironments[rootDeviceIndex]->osInterface = std::make_unique<OSInterface>();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -989,7 +989,7 @@ TEST(DrmMemoryManagerTest2, givenDrmMemoryManagerWhengetSystemSharedMemoryIsCall
|
||||
auto mock = new DrmMockCustom(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(mock));
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
auto memoryManager = std::make_unique<TestedDrmMemoryManager>(false, false, false, *executionEnvironment);
|
||||
@@ -1020,7 +1020,7 @@ TEST(DrmMemoryManagerTest2, WhenGetMinimumSystemSharedMemoryThenCorrectValueIsRe
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(4u);
|
||||
for (auto i = 0u; i < 4u; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmMockCustom(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(mock));
|
||||
@@ -3181,7 +3181,7 @@ struct DrmAllocationTests : public ::testing::Test {
|
||||
void SetUp() override {
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
}
|
||||
|
||||
@@ -3220,7 +3220,7 @@ TEST(DrmMemoryManagerWithExplicitExpectationsTest2, whenObtainFdFromHandleIsCall
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(4u);
|
||||
for (auto i = 0u; i < 4u; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmMockCustom(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(mock));
|
||||
@@ -3244,7 +3244,7 @@ TEST(DrmMemoryManagerWithExplicitExpectationsTest2, whenFailingToObtainFdFromHan
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(4u);
|
||||
for (auto i = 0u; i < 4u; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
auto mock = new DrmMockCustom(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface = std::make_unique<OSInterface>();
|
||||
executionEnvironment->rootDeviceEnvironments[i]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(mock));
|
||||
|
||||
@@ -19,7 +19,7 @@ class DrmTipMock : public DrmMock {
|
||||
public:
|
||||
DrmTipMock(RootDeviceEnvironment &rootDeviceEnvironment) : DrmTipMock(rootDeviceEnvironment, defaultHwInfo.get()) {}
|
||||
DrmTipMock(RootDeviceEnvironment &rootDeviceEnvironment, const HardwareInfo *inputHwInfo) : DrmMock(rootDeviceEnvironment) {
|
||||
rootDeviceEnvironment.setHwInfo(inputHwInfo);
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(inputHwInfo);
|
||||
ioctlHelper.reset();
|
||||
setupIoctlHelper(inputHwInfo->platform.eProductFamily);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -26,7 +26,7 @@ class DrmMockProdDg1 : public DrmTipMock {
|
||||
public:
|
||||
DrmMockProdDg1(RootDeviceEnvironment &rootDeviceEnvironment) : DrmMockProdDg1(rootDeviceEnvironment, defaultHwInfo.get()) {}
|
||||
DrmMockProdDg1(RootDeviceEnvironment &rootDeviceEnvironment, const HardwareInfo *inputHwInfo) : DrmTipMock(rootDeviceEnvironment) {
|
||||
rootDeviceEnvironment.setHwInfo(inputHwInfo);
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(inputHwInfo);
|
||||
}
|
||||
|
||||
void handleQueryItem(QueryItem *queryItem) override {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -313,7 +313,7 @@ TEST(DrmBufferObjectTestPrelim, givenLocalMemoryEnabledWhenCreateDrmVirtualMemor
|
||||
testHwInfo.gtSystemInfo.MultiTileArchInfo.TileCount = 1;
|
||||
testHwInfo.gtSystemInfo.MultiTileArchInfo.Tile0 = 1;
|
||||
testHwInfo.gtSystemInfo.MultiTileArchInfo.TileMask = 0b1;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(&testHwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(&testHwInfo);
|
||||
DrmQueryMock drm(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
|
||||
uint32_t vmId = 0;
|
||||
|
||||
@@ -65,7 +65,7 @@ struct DrmMemoryOperationsHandlerBindFixture : public ::testing::Test {
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numRootDevices);
|
||||
for (uint32_t i = 0u; i < numRootDevices; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
@@ -164,7 +164,7 @@ struct DrmMemoryOperationsHandlerBindFixture2 : public ::testing::Test {
|
||||
executionEnvironment = new ExecutionEnvironment;
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numRootDevices);
|
||||
for (uint32_t i = 0u; i < numRootDevices; i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -28,7 +28,7 @@ class DrmMemManagerFixture {
|
||||
DebugManager.flags.UseExternalAllocatorForSshAndDsh.set(true);
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
DeviceFactory::prepareDeviceEnvironments(*executionEnvironment);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface->setDriverModel(std::unique_ptr<DriverModel>(new DrmMock(*executionEnvironment->rootDeviceEnvironments[0])));
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -354,7 +354,7 @@ TEST(DrmTest, GivenDrmWhenAskedForContextThatFailsThenFalseIsReturned) {
|
||||
TEST(DrmTest, givenDrmWhenOsContextIsCreatedThenCreateAndDestroyNewDrmOsContext) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
{
|
||||
@@ -379,7 +379,7 @@ TEST(DrmTest, givenDrmWhenOsContextIsCreatedThenCreateAndDestroyNewDrmOsContext)
|
||||
|
||||
TEST(DrmTest, whenCreatingDrmContextWithVirtualMemoryAddressSpaceThenProperVmIdIsSet) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -396,7 +396,7 @@ TEST(DrmTest, whenCreatingDrmContextWithVirtualMemoryAddressSpaceThenProperVmIdI
|
||||
|
||||
TEST(DrmTest, whenCreatingDrmContextWithNoVirtualMemoryAddressSpaceThenProperContextIdIsSet) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -412,7 +412,7 @@ TEST(DrmTest, whenCreatingDrmContextWithNoVirtualMemoryAddressSpaceThenProperCon
|
||||
|
||||
TEST(DrmTest, givenDrmAndNegativeCheckNonPersistentContextsSupportWhenOsContextIsCreatedThenReceivedContextParamRequestCountReturnsCorrectValue) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -439,7 +439,7 @@ TEST(DrmTest, givenDrmAndNegativeCheckNonPersistentContextsSupportWhenOsContextI
|
||||
|
||||
TEST(DrmTest, givenDrmPreemptionEnabledAndLowPriorityEngineWhenCreatingOsContextThenCallSetContextPriorityIoctl) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -641,7 +641,7 @@ TEST(HwDeviceId, whenHwDeviceIdIsDestroyedThenFileDescriptorIsClosed) {
|
||||
|
||||
TEST(DrmTest, givenDrmWhenCreatingOsContextThenCreateDrmContextWithVmId) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -741,7 +741,7 @@ TEST(DrmTest, givenPerContextVMRequiredWhenCreatingOsContextsForRootDeviceThenIm
|
||||
|
||||
TEST(DrmTest, givenNoPerContextVmsDrmWhenCreatingOsContextsThenVmIdIsNotQueriedAndStored) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DrmMock drmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
@@ -761,7 +761,7 @@ TEST(DrmTest, givenProgramDebuggingAndContextDebugAvailableWhenCreatingContextTh
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -781,7 +781,7 @@ TEST(DrmTest, givenProgramDebuggingAndContextDebugAvailableWhenCreatingContextFo
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -797,7 +797,7 @@ TEST(DrmTest, givenProgramDebuggingAndContextDebugAvailableWhenCreatingContextFo
|
||||
|
||||
TEST(DrmTest, givenNotEnabledDebuggingOrContextDebugUnsupportedWhenCreatingContextThenCooperativeFlagIsNotPassedToCreateDrmContext) {
|
||||
auto executionEnvironment = std::make_unique<MockExecutionEnvironment>();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
@@ -873,7 +873,7 @@ TEST(DrmTest, givenProgramDebuggingWhenCreatingContextThenUnrecoverableContextIs
|
||||
auto executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->setDebuggingEnabled();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
executionEnvironment->calculateMaxOsContextCount();
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface = std::make_unique<OSInterface>();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -34,7 +34,7 @@ struct ProductHelperTestLinux : public ProductHelperTest {
|
||||
ProductHelperTest::SetUp();
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
|
||||
drm = new DrmMock(*executionEnvironment->rootDeviceEnvironments[0]);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->osInterface.reset(new OSInterface());
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -27,7 +27,7 @@ struct MultipleDeviceUuidTest : public ::testing::Test {
|
||||
ExecutionEnvironment *executionEnvironment = new ExecutionEnvironment();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(numRootDevices);
|
||||
for (auto i = 0u; i < executionEnvironment->rootDeviceEnvironments.size(); i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -358,7 +358,7 @@ TEST_F(IoctlPrelimHelperTests, givenPrelimWhenGettingEuStallFdParameterThenCorre
|
||||
class DrmMockIoctl : public DrmMock {
|
||||
public:
|
||||
DrmMockIoctl(RootDeviceEnvironment &rootDeviceEnvironment) : DrmMock(rootDeviceEnvironment) {
|
||||
rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
}
|
||||
int handleRemainingRequests(DrmIoctl request, void *arg) override {
|
||||
if (request == DrmIoctl::Query) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -692,7 +692,7 @@ TEST(OSTimeWinLinuxTests, givenOSInterfaceWhenGetCpuGpuTimeThenGetCpuTimeFromOsT
|
||||
|
||||
std::unique_ptr<MockWddmLinux> wddm = std::make_unique<MockWddmLinux>(std::move(hwDeviceIdIn), mockRootDeviceEnvironment);
|
||||
*wddm->gfxPlatform = NEO::defaultHwInfo->platform;
|
||||
mockRootDeviceEnvironment.setHwInfo(NEO::defaultHwInfo.get());
|
||||
mockRootDeviceEnvironment.setHwInfoAndInitHelpers(NEO::defaultHwInfo.get());
|
||||
auto mockDeviceTimeWddm = std::make_unique<MockDeviceTimeWddm>(wddm.get());
|
||||
osInterface->setDriverModel(std::move(wddm));
|
||||
std::unique_ptr<NEO::DeviceTime> deviceTime = std::unique_ptr<NEO::DeviceTime>(mockDeviceTimeWddm.release());
|
||||
|
||||
@@ -336,7 +336,7 @@ using WddmPreemptionHeaderTests = ::Test<WddmPreemptionHeaderFixture>;
|
||||
|
||||
TEST_F(WddmPreemptionHeaderTests, givenWddmCommandStreamReceiverWhenPreemptionIsOffWhenWorkloadIsSubmittedThenHeaderDoesntHavePreemptionFieldSet) {
|
||||
hwInfo->capabilityTable.defaultPreemptionMode = PreemptionMode::Disabled;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto csr = std::make_unique<MockWddmCsr<DEFAULT_TEST_FAMILY_NAME>>(*executionEnvironment, 0, 1);
|
||||
@@ -363,7 +363,7 @@ TEST_F(WddmPreemptionHeaderTests, givenWddmCommandStreamReceiverWhenPreemptionIs
|
||||
|
||||
TEST_F(WddmPreemptionHeaderTests, givenWddmCommandStreamReceiverWhenPreemptionIsOnWhenWorkloadIsSubmittedThenHeaderDoesHavePreemptionFieldSet) {
|
||||
hwInfo->capabilityTable.defaultPreemptionMode = PreemptionMode::MidThread;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto csr = std::make_unique<MockWddmCsr<DEFAULT_TEST_FAMILY_NAME>>(*executionEnvironment, 0, 1);
|
||||
@@ -391,7 +391,7 @@ TEST_F(WddmPreemptionHeaderTests, givenWddmCommandStreamReceiverWhenPreemptionIs
|
||||
|
||||
TEST_F(WddmPreemptionHeaderTests, givenDeviceSupportingPreemptionWhenCommandStreamReceiverIsCreatedThenHeaderContainsPreemptionFieldSet) {
|
||||
hwInfo->capabilityTable.defaultPreemptionMode = PreemptionMode::MidThread;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto commandStreamReceiver = std::make_unique<MockWddmCsr<DEFAULT_TEST_FAMILY_NAME>>(*executionEnvironment, 0, 1);
|
||||
@@ -402,7 +402,7 @@ TEST_F(WddmPreemptionHeaderTests, givenDeviceSupportingPreemptionWhenCommandStre
|
||||
|
||||
TEST_F(WddmPreemptionHeaderTests, givenDevicenotSupportingPreemptionWhenCommandStreamReceiverIsCreatedThenHeaderPreemptionFieldIsNotSet) {
|
||||
hwInfo->capabilityTable.defaultPreemptionMode = PreemptionMode::Disabled;
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(hwInfo);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
auto commandStreamReceiver = std::make_unique<MockWddmCsr<DEFAULT_TEST_FAMILY_NAME>>(*executionEnvironment, 0, 1);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
* Copyright (C) 2022-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -28,7 +28,7 @@ class WddmMemManagerFixture {
|
||||
void setUp() {
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DeviceFactory::prepareDeviceEnvironments(*executionEnvironment);
|
||||
@@ -63,7 +63,7 @@ TEST(WddmMemoryReservationFailTest, givenWddmMemoryManagerWhenGpuAddressReservat
|
||||
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DeviceFactory::prepareDeviceEnvironments(*executionEnvironment);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -29,7 +29,7 @@ class WddmMemManagerFixture {
|
||||
DebugManager.flags.UseExternalAllocatorForSshAndDsh.set(true);
|
||||
executionEnvironment = std::make_unique<ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(1);
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[0]->initGmm();
|
||||
|
||||
DeviceFactory::prepareDeviceEnvironments(*executionEnvironment);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -245,7 +245,7 @@ TEST_F(WddmTests, GivenProperTopologyDataWhenQueryingTopologyThenExpectTrue) {
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[i].Enabled = false;
|
||||
}
|
||||
|
||||
wddm->rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
wddm->rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
EXPECT_TRUE(wddm->buildTopologyMapping());
|
||||
const auto &topologyMap = wddm->getTopologyMap();
|
||||
EXPECT_EQ(topologyMap.size(), 1u);
|
||||
@@ -280,7 +280,7 @@ TEST_F(WddmTests, GivenMoreThanOneEnabledSliceWhenQueryingTopologyThenExpectTrue
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[index].Enabled = false;
|
||||
}
|
||||
|
||||
wddm->rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
wddm->rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
EXPECT_TRUE(wddm->buildTopologyMapping());
|
||||
const auto &topologyMap = wddm->getTopologyMap();
|
||||
EXPECT_EQ(topologyMap.size(), 1u);
|
||||
@@ -304,7 +304,7 @@ TEST_F(WddmTests, GivenNoSubsliceEnabledWhenQueryingTopologyThenExpectFalse) {
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[0].DSSInfo[0].SubSlice[0].Enabled = false;
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[0].DSSInfo[0].SubSlice[1].Enabled = false;
|
||||
|
||||
wddm->rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
wddm->rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
EXPECT_FALSE(wddm->buildTopologyMapping());
|
||||
}
|
||||
|
||||
@@ -320,7 +320,7 @@ TEST_F(WddmTests, GivenNoEuThreadsEnabledWhenQueryingTopologyThenExpectFalse) {
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[0].DSSInfo[0].SubSlice[0].Enabled = true;
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[0].DSSInfo[0].SubSlice[0].EuEnabledCount = 0;
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[0].DSSInfo[0].SubSlice[1].Enabled = false;
|
||||
wddm->rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
wddm->rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
EXPECT_FALSE(wddm->buildTopologyMapping());
|
||||
}
|
||||
|
||||
@@ -330,7 +330,7 @@ TEST_F(WddmTests, GivenNoSliceEnabledWhenQueryingTopologyThenExpectFalse) {
|
||||
for (uint32_t i = 0; i < GT_MAX_SLICE; i++) {
|
||||
defaultHwInfo.get()->gtSystemInfo.SliceInfo[i].Enabled = false;
|
||||
}
|
||||
wddm->rootDeviceEnvironment.setHwInfo(defaultHwInfo.get());
|
||||
wddm->rootDeviceEnvironment.setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
EXPECT_FALSE(wddm->buildTopologyMapping());
|
||||
}
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "shared/source/built_ins/built_ins.h"
|
||||
#include "shared/source/command_container/implicit_scaling.h"
|
||||
#include "shared/source/compiler_interface/default_cache_config.h"
|
||||
#include "shared/source/execution_environment/root_device_environment.h"
|
||||
#include "shared/source/memory_manager/compression_selector.h"
|
||||
#include "shared/source/page_fault_manager/cpu_page_fault_manager.h"
|
||||
|
||||
@@ -24,4 +25,8 @@ void PageFaultManager::transferToGpu(void *ptr, void *cmdQ) {
|
||||
}
|
||||
CompilerCacheConfig getDefaultCompilerCacheConfig() { return {}; }
|
||||
const char *getAdditionalBuiltinAsString(EBuiltInOps::Type builtin) { return nullptr; }
|
||||
|
||||
void RootDeviceEnvironment::initApiGfxCoreHelper() {
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -459,7 +459,7 @@ TEST_F(TagAllocatorTest, givenMultipleRootDevicesWhenPopulatingTagsThenCreateMul
|
||||
auto executionEnvironment = std::make_unique<NEO::ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(maxRootDeviceIndex + 1);
|
||||
for (auto i = 0u; i < executionEnvironment->rootDeviceEnvironments.size(); i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
|
||||
@@ -489,7 +489,7 @@ HWTEST_F(TagAllocatorTest, givenMultipleRootDevicesWhenCallingMakeResidentThenUs
|
||||
auto executionEnvironment = std::make_unique<NEO::ExecutionEnvironment>();
|
||||
executionEnvironment->prepareRootDeviceEnvironments(maxRootDeviceIndex + 1);
|
||||
for (auto i = 0u; i < executionEnvironment->rootDeviceEnvironments.size(); i++) {
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfo(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->setHwInfoAndInitHelpers(defaultHwInfo.get());
|
||||
executionEnvironment->rootDeviceEnvironments[i]->initGmm();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user