mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 23:56:39 +08:00
refactor: pass additional enqueue params
Related-To: NEO-12591 Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
18d828421d
commit
4d6265a46c
@@ -60,7 +60,9 @@ inline void HardwareInterface<GfxFamily>::programWalker(
|
|||||||
uint32_t dim = dispatchInfo.getDim();
|
uint32_t dim = dispatchInfo.getDim();
|
||||||
uint32_t simd = kernelInfo.getMaxSimdSize();
|
uint32_t simd = kernelInfo.getMaxSimdSize();
|
||||||
|
|
||||||
auto numChannels = kernelInfo.kernelDescriptor.kernelAttributes.numLocalIdChannels;
|
const auto &kernelAttributes = kernelInfo.kernelDescriptor.kernelAttributes;
|
||||||
|
|
||||||
|
auto numChannels = kernelAttributes.numLocalIdChannels;
|
||||||
|
|
||||||
size_t startWorkGroups[3] = {walkerArgs.startOfWorkgroups->x, walkerArgs.startOfWorkgroups->y, walkerArgs.startOfWorkgroups->z};
|
size_t startWorkGroups[3] = {walkerArgs.startOfWorkgroups->x, walkerArgs.startOfWorkgroups->y, walkerArgs.startOfWorkgroups->z};
|
||||||
size_t numWorkGroups[3] = {walkerArgs.numberOfWorkgroups->x, walkerArgs.numberOfWorkgroups->y, walkerArgs.numberOfWorkgroups->z};
|
size_t numWorkGroups[3] = {walkerArgs.numberOfWorkgroups->x, walkerArgs.numberOfWorkgroups->y, walkerArgs.numberOfWorkgroups->z};
|
||||||
@@ -71,10 +73,10 @@ inline void HardwareInterface<GfxFamily>::programWalker(
|
|||||||
bool localIdsGenerationByRuntime = kernelUsesLocalIds && EncodeDispatchKernel<GfxFamily>::isRuntimeLocalIdsGenerationRequired(
|
bool localIdsGenerationByRuntime = kernelUsesLocalIds && EncodeDispatchKernel<GfxFamily>::isRuntimeLocalIdsGenerationRequired(
|
||||||
numChannels,
|
numChannels,
|
||||||
walkerArgs.localWorkSizes,
|
walkerArgs.localWorkSizes,
|
||||||
std::array<uint8_t, 3>{{kernelInfo.kernelDescriptor.kernelAttributes.workgroupWalkOrder[0],
|
std::array<uint8_t, 3>{{kernelAttributes.workgroupWalkOrder[0],
|
||||||
kernelInfo.kernelDescriptor.kernelAttributes.workgroupWalkOrder[1],
|
kernelAttributes.workgroupWalkOrder[1],
|
||||||
kernelInfo.kernelDescriptor.kernelAttributes.workgroupWalkOrder[2]}},
|
kernelAttributes.workgroupWalkOrder[2]}},
|
||||||
kernelInfo.kernelDescriptor.kernelAttributes.flags.requiresWorkgroupWalkOrder,
|
kernelAttributes.flags.requiresWorkgroupWalkOrder,
|
||||||
requiredWalkOrder,
|
requiredWalkOrder,
|
||||||
simd);
|
simd);
|
||||||
|
|
||||||
@@ -142,7 +144,9 @@ inline void HardwareInterface<GfxFamily>::programWalker(
|
|||||||
}
|
}
|
||||||
bool requiredSystemFence = kernelSystemAllocation && walkerArgs.event != nullptr;
|
bool requiredSystemFence = kernelSystemAllocation && walkerArgs.event != nullptr;
|
||||||
auto maxFrontEndThreads = device.getDeviceInfo().maxFrontEndThreads;
|
auto maxFrontEndThreads = device.getDeviceInfo().maxFrontEndThreads;
|
||||||
EncodeWalkerArgs encodeWalkerArgs{kernel.getExecutionType(), requiredSystemFence, kernelInfo.kernelDescriptor, NEO::RequiredDispatchWalkOrder::none, 0, maxFrontEndThreads};
|
|
||||||
|
EncodeWalkerArgs encodeWalkerArgs{kernel.getExecutionType(), requiredSystemFence, kernelInfo.kernelDescriptor, kernelAttributes.walkOrder, kernelAttributes.additionalSize, maxFrontEndThreads};
|
||||||
|
|
||||||
EncodeDispatchKernel<GfxFamily>::template encodeAdditionalWalkerFields<WalkerType>(rootDeviceEnvironment, walkerCmd, encodeWalkerArgs);
|
EncodeDispatchKernel<GfxFamily>::template encodeAdditionalWalkerFields<WalkerType>(rootDeviceEnvironment, walkerCmd, encodeWalkerArgs);
|
||||||
|
|
||||||
auto devices = queueCsr.getOsContext().getDeviceBitfield();
|
auto devices = queueCsr.getOsContext().getDeviceBitfield();
|
||||||
@@ -162,6 +166,10 @@ inline void HardwareInterface<GfxFamily>::programWalker(
|
|||||||
uint32_t partitionCount = 0u;
|
uint32_t partitionCount = 0u;
|
||||||
RequiredPartitionDim requiredPartitionDim = kernel.usesImages() ? RequiredPartitionDim::x : RequiredPartitionDim::none;
|
RequiredPartitionDim requiredPartitionDim = kernel.usesImages() ? RequiredPartitionDim::x : RequiredPartitionDim::none;
|
||||||
|
|
||||||
|
if (kernelAttributes.partitionDim != NEO::RequiredPartitionDim::none) {
|
||||||
|
requiredPartitionDim = kernelAttributes.partitionDim;
|
||||||
|
}
|
||||||
|
|
||||||
ImplicitScalingDispatchCommandArgs implicitScalingArgs{
|
ImplicitScalingDispatchCommandArgs implicitScalingArgs{
|
||||||
workPartitionAllocationGpuVa, // workPartitionAllocationGpuVa
|
workPartitionAllocationGpuVa, // workPartitionAllocationGpuVa
|
||||||
&hwInfo, // hwInfo
|
&hwInfo, // hwInfo
|
||||||
|
|||||||
Reference in New Issue
Block a user