@@ -3085,14 +3085,15 @@ ur_result_t ExecCGCommand::enqueueImpCommandBuffer() {
30853085 " Can't get memory object due to no allocation available " +
30863086 codeToString (UR_RESULT_ERROR_INVALID_MEM_OBJECT));
30873087 };
3088- std::for_each (std::begin (HandlerReq), std::end (HandlerReq), ReqToMemConv);
3088+ std::for_each (std::begin (HandlerReq), std::end (HandlerReq),
3089+ std::move (ReqToMemConv));
30893090
30903091 ur_exp_command_buffer_handle_t InteropCommandBuffer =
30913092 ChildCommandBuffer ? ChildCommandBuffer : MCommandBuffer;
3092- interop_handle IH{ReqToMem, MQueue, DeviceImpl, ContextImpl,
3093+ interop_handle IH{std::move ( ReqToMem) , MQueue, DeviceImpl, ContextImpl,
30933094 InteropCommandBuffer};
30943095 CommandBufferNativeCommandData CustomOpData{
3095- IH , HostTask->MHostTask ->MInteropTask };
3096+ std::move (IH) , HostTask->MHostTask ->MInteropTask };
30963097
30973098#ifndef __INTEL_PREVIEW_BREAKING_CHANGES
30983099 // CMPLRLLVM-66082
@@ -3423,7 +3424,8 @@ ur_result_t ExecCGCommand::enqueueImpQueue() {
34233424 " Can't get memory object due to no allocation available " +
34243425 codeToString (UR_RESULT_ERROR_INVALID_MEM_OBJECT));
34253426 };
3426- std::for_each (std::begin (HandlerReq), std::end (HandlerReq), ReqToMemConv);
3427+ std::for_each (std::begin (HandlerReq), std::end (HandlerReq),
3428+ std::move (ReqToMemConv));
34273429 std::sort (std::begin (ReqToMem), std::end (ReqToMem));
34283430 }
34293431
@@ -3488,12 +3490,13 @@ ur_result_t ExecCGCommand::enqueueImpQueue() {
34883490 " Can't get memory object due to no allocation available " +
34893491 codeToString (UR_RESULT_ERROR_INVALID_MEM_OBJECT));
34903492 };
3491- std::for_each (std::begin (HandlerReq), std::end (HandlerReq), ReqToMemConv);
3493+ std::for_each (std::begin (HandlerReq), std::end (HandlerReq),
3494+ std::move (ReqToMemConv));
34923495 std::sort (std::begin (ReqToMem), std::end (ReqToMem));
34933496 }
34943497
34953498 EnqueueNativeCommandData CustomOpData{
3496- interop_handle{ReqToMem, HostTask->MQueue ,
3499+ interop_handle{std::move ( ReqToMem) , HostTask->MQueue ,
34973500 HostTask->MQueue ->getDeviceImplPtr (),
34983501 HostTask->MQueue ->getContextImplPtr ()},
34993502 HostTask->MHostTask ->MInteropTask };
0 commit comments