Skip to content

Commit 6a91b57

Browse files
committed
fix test fails
Signed-off-by: Sergey V Maslov <[email protected]>
1 parent 277dc9c commit 6a91b57

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

sycl/plugins/level_zero/pi_level_zero.cpp

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -947,11 +947,16 @@ pi_result _pi_queue::executeCommandList(pi_command_list_ptr_t CommandList,
947947
// as we want to strictly follow the batching the user specified.
948948
if (OKToBatchCommand && this->isBatchingAllowed() &&
949949
(!UseDynamicBatching || !CurrentlyEmpty)) {
950-
if (hasOpenCommandList() && OpenCommandList != CommandList)
951-
die("executeCommandList: OpenCommandList should be equal to"
952-
"null or CommandList");
950+
if (hasOpenCommandList()) {
951+
if (OpenCommandList != CommandList)
952+
die("executeCommandList: OpenCommandList should be equal to"
953+
"null or CommandList");
953954

954-
if (OpenCommandList->second.EventList.size() < QueueBatchSize) {
955+
if (OpenCommandList->second.size() < QueueBatchSize) {
956+
return PI_SUCCESS;
957+
}
958+
}
959+
else {
955960
OpenCommandList = CommandList;
956961
return PI_SUCCESS;
957962
}

0 commit comments

Comments
 (0)