SWDEV-547453 Release the kernel command if the operation returns an error (#807)
* SWDEV-547453 Release the kernel command if the operation returns an error
* SWDEV-547453 - Initialize parameters_ to default value
* SWDEV-547453 - Run clang-format
[ROCm/clr commit: a15957fee9]
This commit is contained in:
committed by
GitHub
parent
5775e9202b
commit
208d124f54
@@ -421,20 +421,21 @@ const Context& Command::context() const { return queue_->context(); }
|
||||
NDRangeKernelCommand::NDRangeKernelCommand(HostQueue& queue, const EventWaitList& eventWaitList,
|
||||
Kernel& kernel, const NDRangeContainer& sizes,
|
||||
uint32_t sharedMemBytes, uint32_t extraParam,
|
||||
uint32_t gridId, uint32_t numGrids,
|
||||
uint64_t prevGridSum, uint64_t allGridSum,
|
||||
uint32_t firstDevice, bool forceProfiling) :
|
||||
Command(queue, CL_COMMAND_NDRANGE_KERNEL, eventWaitList, AMD_SERIALIZE_KERNEL |
|
||||
(HIP_LAUNCH_BLOCKING << 1)),
|
||||
kernel_(kernel),
|
||||
sizes_(sizes),
|
||||
sharedMemBytes_(sharedMemBytes),
|
||||
extraParam_(extraParam),
|
||||
gridId_(gridId),
|
||||
numGrids_(numGrids),
|
||||
prevGridSum_(prevGridSum),
|
||||
allGridSum_(allGridSum),
|
||||
firstDevice_(firstDevice) {
|
||||
uint32_t gridId, uint32_t numGrids, uint64_t prevGridSum,
|
||||
uint64_t allGridSum, uint32_t firstDevice,
|
||||
bool forceProfiling)
|
||||
: Command(queue, CL_COMMAND_NDRANGE_KERNEL, eventWaitList,
|
||||
AMD_SERIALIZE_KERNEL | (HIP_LAUNCH_BLOCKING << 1)),
|
||||
kernel_(kernel),
|
||||
sizes_(sizes),
|
||||
sharedMemBytes_(sharedMemBytes),
|
||||
extraParam_(extraParam),
|
||||
gridId_(gridId),
|
||||
numGrids_(numGrids),
|
||||
prevGridSum_(prevGridSum),
|
||||
allGridSum_(allGridSum),
|
||||
firstDevice_(firstDevice),
|
||||
parameters_(nullptr) {
|
||||
auto& device = queue.device();
|
||||
auto devKernel = const_cast<device::Kernel*>(kernel.getDeviceKernel(device));
|
||||
if (cooperativeGroups()) {
|
||||
|
||||
Reference in New Issue
Block a user