Skip to content

Commit 9ebbd0a

Browse files
authored
[UR] Replace the pKMemObj argument with bool callWithArgs (#20699)
Replace the `pKMemObj` argument of `appendKernelLaunchLocked()` with `bool callWithArgs`. Signed-off-by: Lukasz Dorau <[email protected]>
1 parent f538636 commit 9ebbd0a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

unified-runtime/source/adapters/level_zero/v2/command_list_manager.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ ur_result_t ur_command_list_manager::appendKernelLaunchLocked(
155155
ur_kernel_handle_t hKernel, ze_kernel_handle_t hZeKernel, uint32_t workDim,
156156
const size_t *pGlobalWorkOffset, const size_t *pGlobalWorkSize,
157157
const size_t *pLocalWorkSize, wait_list_view &waitListView,
158-
ur_event_handle_t phEvent, bool cooperative, std::vector<void *> *pKMemObj,
158+
ur_event_handle_t phEvent, bool cooperative, bool callWithArgs,
159159
void *pNext) {
160160

161161
ze_group_count_t zeThreadGroupDimensions{1, 1, 1};
@@ -170,7 +170,7 @@ ur_result_t ur_command_list_manager::appendKernelLaunchLocked(
170170
hContext.get(), hDevice.get(), pGlobalWorkOffset, workDim, WG[0], WG[1],
171171
WG[2], getZeCommandList(), waitListView));
172172

173-
if (pKMemObj) {
173+
if (callWithArgs) {
174174
// zeCommandListAppendLaunchKernelWithArguments
175175
TRACK_SCOPE_LATENCY("ur_command_list_manager::"
176176
"zeCommandListAppendLaunchKernelWithArguments");
@@ -1228,7 +1228,7 @@ ur_result_t ur_command_list_manager::appendKernelLaunchWithArgsExpNew(
12281228
return appendKernelLaunchLocked(
12291229
hKernel, hZeKernel, workDim, pGlobalWorkOffset, pGlobalWorkSize,
12301230
pLocalWorkSize, waitListView, phEvent, cooperativeKernelLaunchRequested,
1231-
&hKernel->kernelMemObj, pNext);
1231+
true /* callWithArgs */, pNext);
12321232
}
12331233

12341234
ur_result_t ur_command_list_manager::appendKernelLaunchWithArgsExp(

unified-runtime/source/adapters/level_zero/v2/command_list_manager.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ struct ur_command_list_manager {
280280
uint32_t workDim, const size_t *pGlobalWorkOffset,
281281
const size_t *pGlobalWorkSize, const size_t *pLocalWorkSize,
282282
wait_list_view &waitListView, ur_event_handle_t phEvent, bool cooperative,
283-
std::vector<void *> *pKMemObj = nullptr, void *pNext = nullptr);
283+
bool withArgs = false, void *pNext = nullptr);
284284

285285
ur_result_t appendKernelLaunchUnlocked(
286286
ur_kernel_handle_t hKernel, uint32_t workDim,

0 commit comments

Comments
 (0)