diff --git a/level_zero/core/source/cmdqueue/cmdqueue_hw.inl b/level_zero/core/source/cmdqueue/cmdqueue_hw.inl index 53ab25cb61..644e7efe94 100644 --- a/level_zero/core/source/cmdqueue/cmdqueue_hw.inl +++ b/level_zero/core/source/cmdqueue/cmdqueue_hw.inl @@ -269,10 +269,12 @@ ze_result_t CommandQueueHw::executeCommandLists( NEO::PreemptionHelper::programStateSip(child, *neoDevice); } - NEO::PreemptionHelper::programCmdStream(child, - cmdQueuePreemption, - commandQueuePreemptionMode, - csr->getPreemptionAllocation()); + if (cmdQueuePreemption != commandQueuePreemptionMode) { + NEO::PreemptionHelper::programCmdStream(child, + cmdQueuePreemption, + commandQueuePreemptionMode, + csr->getPreemptionAllocation()); + } statePreemption = cmdQueuePreemption; const bool sipKernelUsed = devicePreemption == NEO::PreemptionMode::MidThread ||