File tree 1 file changed +6
-1
lines changed
source/adapters/level_zero
1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -130,8 +130,10 @@ ur_result_t ur_queue_handle_legacy_t_::enqueueKernelLaunch(
130
130
*OutEvent // /< [in,out][optional] return an event object that identifies
131
131
// /< this particular kernel execution instance.
132
132
) {
133
- auto Queue = this ;
133
+ UR_ASSERT (WorkDim > 0 , UR_RESULT_ERROR_INVALID_WORK_DIMENSION);
134
+ UR_ASSERT (WorkDim < 4 , UR_RESULT_ERROR_INVALID_WORK_DIMENSION);
134
135
136
+ auto Queue = this ;
135
137
ze_kernel_handle_t ZeKernel{};
136
138
UR_CALL (getZeKernel (Queue, Kernel, &ZeKernel));
137
139
@@ -337,6 +339,9 @@ ur_result_t ur_queue_handle_legacy_t_::enqueueCooperativeKernelLaunchExp(
337
339
*OutEvent // /< [in,out][optional] return an event object that identifies
338
340
// /< this particular kernel execution instance.
339
341
) {
342
+ UR_ASSERT (WorkDim > 0 , UR_RESULT_ERROR_INVALID_WORK_DIMENSION);
343
+ UR_ASSERT (WorkDim < 4 , UR_RESULT_ERROR_INVALID_WORK_DIMENSION);
344
+
340
345
auto Queue = this ;
341
346
auto ZeDevice = Queue->Device ->ZeDevice ;
342
347
You can’t perform that action at this time.
0 commit comments