refactor: use cmd list member instead of getting l0GfxCoreHelper
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
parent
18b19373c3
commit
0164288fce
|
@ -381,6 +381,7 @@ struct CommandListCoreFamily : public CommandListImp {
|
||||||
bool inOrderAtomicSignalingEnabled = false;
|
bool inOrderAtomicSignalingEnabled = false;
|
||||||
bool allowCbWaitEventsNoopDispatch = false;
|
bool allowCbWaitEventsNoopDispatch = false;
|
||||||
bool copyOperationFenceSupported = false;
|
bool copyOperationFenceSupported = false;
|
||||||
|
bool implicitSynchronizedDispatchForCooperativeKernelsAllowed = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <PRODUCT_FAMILY gfxProductFamily>
|
template <PRODUCT_FAMILY gfxProductFamily>
|
||||||
|
|
|
@ -219,6 +219,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::initialize(Device *device, NEO
|
||||||
auto &rootDeviceEnvironment = neoDevice->getRootDeviceEnvironment();
|
auto &rootDeviceEnvironment = neoDevice->getRootDeviceEnvironment();
|
||||||
auto &productHelper = rootDeviceEnvironment.getHelper<NEO::ProductHelper>();
|
auto &productHelper = rootDeviceEnvironment.getHelper<NEO::ProductHelper>();
|
||||||
auto &gfxCoreHelper = neoDevice->getGfxCoreHelper();
|
auto &gfxCoreHelper = neoDevice->getGfxCoreHelper();
|
||||||
|
auto &l0GfxCoreHelper = device->getL0GfxCoreHelper();
|
||||||
auto &compilerProductHelper = neoDevice->getCompilerProductHelper();
|
auto &compilerProductHelper = neoDevice->getCompilerProductHelper();
|
||||||
auto gmmHelper = rootDeviceEnvironment.getGmmHelper();
|
auto gmmHelper = rootDeviceEnvironment.getGmmHelper();
|
||||||
|
|
||||||
|
@ -249,6 +250,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::initialize(Device *device, NEO
|
||||||
this->scratchAddressPatchingEnabled = (this->heaplessModeEnabled && !isImmediateType());
|
this->scratchAddressPatchingEnabled = (this->heaplessModeEnabled && !isImmediateType());
|
||||||
this->copyOperationFenceSupported = (isCopyOnly() || isCopyOffloadEnabled()) && productHelper.isDeviceToHostCopySignalingFenceRequired();
|
this->copyOperationFenceSupported = (isCopyOnly() || isCopyOffloadEnabled()) && productHelper.isDeviceToHostCopySignalingFenceRequired();
|
||||||
this->defaultPipelinedThreadArbitrationPolicy = gfxCoreHelper.getDefaultThreadArbitrationPolicy();
|
this->defaultPipelinedThreadArbitrationPolicy = gfxCoreHelper.getDefaultThreadArbitrationPolicy();
|
||||||
|
this->implicitSynchronizedDispatchForCooperativeKernelsAllowed = l0GfxCoreHelper.implicitSynchronizedDispatchForCooperativeKernelsAllowed();
|
||||||
if (NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get() != -1) {
|
if (NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get() != -1) {
|
||||||
this->defaultPipelinedThreadArbitrationPolicy = NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get();
|
this->defaultPipelinedThreadArbitrationPolicy = NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get();
|
||||||
}
|
}
|
||||||
|
@ -391,7 +393,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendLaunchKernel(ze_kernel_h
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (launchParams.isCooperative && device->getL0GfxCoreHelper().implicitSynchronizedDispatchForCooperativeKernelsAllowed()) {
|
if (launchParams.isCooperative && this->implicitSynchronizedDispatchForCooperativeKernelsAllowed) {
|
||||||
enableSynchronizedDispatch(NEO::SynchronizedDispatchMode::full);
|
enableSynchronizedDispatch(NEO::SynchronizedDispatchMode::full);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue