mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-01 04:23:00 +08:00
Revert "refactor: remove redundant exec environment pointer from L0::DeviceImp"
This reverts commit c7893fb3ed.
Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
f754d671a3
commit
523bd92db4
@@ -95,6 +95,7 @@ struct Device : _ze_device_handle_t {
|
||||
|
||||
virtual ~Device() = default;
|
||||
|
||||
virtual void *getExecEnvironment() = 0;
|
||||
virtual BuiltinFunctionsLib *getBuiltinFunctionsLib() = 0;
|
||||
virtual uint32_t getMOCS(bool l3enabled, bool l1enabled) = 0;
|
||||
virtual uint32_t getMaxNumHwThreads() const = 0;
|
||||
|
||||
@@ -1462,6 +1462,8 @@ ze_result_t DeviceImp::activateMetricGroupsDeferred(uint32_t count,
|
||||
return status;
|
||||
}
|
||||
|
||||
void *DeviceImp::getExecEnvironment() { return execEnvironment; }
|
||||
|
||||
BuiltinFunctionsLib *DeviceImp::getBuiltinFunctionsLib() { return builtins.get(); }
|
||||
|
||||
uint32_t DeviceImp::getMOCS(bool l3enabled, bool l1enabled) {
|
||||
@@ -1540,6 +1542,7 @@ Device *Device::create(DriverHandle *driverHandle, NEO::Device *neoDevice, bool
|
||||
auto &rootDeviceEnvironment = neoDevice->getRootDeviceEnvironment();
|
||||
auto &gfxCoreHelper = rootDeviceEnvironment.getHelper<NEO::GfxCoreHelper>();
|
||||
|
||||
device->execEnvironment = (void *)neoDevice->getExecutionEnvironment();
|
||||
device->allocationsForReuse = std::make_unique<NEO::AllocationsList>();
|
||||
bool platformImplicitScaling = gfxCoreHelper.platformSupportsImplicitScaling(rootDeviceEnvironment);
|
||||
device->implicitScalingCapable = NEO::ImplicitScalingHelper::isImplicitScalingEnabled(neoDevice->getDeviceBitfield(), platformImplicitScaling);
|
||||
|
||||
@@ -76,6 +76,7 @@ struct DeviceImp : public Device, NEO::NonCopyableAndNonMovableClass {
|
||||
|
||||
ze_result_t systemBarrier() override;
|
||||
ze_result_t synchronize() override;
|
||||
void *getExecEnvironment() override;
|
||||
BuiltinFunctionsLib *getBuiltinFunctionsLib() override;
|
||||
uint32_t getMOCS(bool l3enabled, bool l1enabled) override;
|
||||
const NEO::GfxCoreHelper &getGfxCoreHelper() override;
|
||||
@@ -128,6 +129,7 @@ struct DeviceImp : public Device, NEO::NonCopyableAndNonMovableClass {
|
||||
uint32_t getPhysicalSubDeviceId();
|
||||
|
||||
bool isSubdevice = false;
|
||||
void *execEnvironment = nullptr;
|
||||
std::unique_ptr<BuiltinFunctionsLib> builtins;
|
||||
std::unique_ptr<MetricDeviceContext> metricContext;
|
||||
std::unique_ptr<CacheReservation> cacheReservation;
|
||||
|
||||
Reference in New Issue
Block a user