@@ -1029,12 +1029,12 @@ void Command::copySubmissionCodeLocation() {
10291029}
10301030
10311031AllocaCommandBase::AllocaCommandBase (CommandType Type, queue_impl *Queue,
1032- Requirement Req,
1032+ const Requirement & Req,
10331033 AllocaCommandBase *LinkedAllocaCmd,
10341034 bool IsConst)
10351035 : Command(Type, Queue), MLinkedAllocaCmd(LinkedAllocaCmd),
10361036 MIsLeaderAlloca(nullptr == LinkedAllocaCmd), MIsConst(IsConst),
1037- MRequirement(std::move( Req) ), MReleaseCmd(Queue, this ) {
1037+ MRequirement(Req), MReleaseCmd(Queue, this ) {
10381038 MRequirement.MAccessMode = access::mode::read_write;
10391039 emitInstrumentationDataProxy ();
10401040}
@@ -1071,11 +1071,11 @@ bool AllocaCommandBase::supportsPostEnqueueCleanup() const { return false; }
10711071
10721072bool AllocaCommandBase::readyForCleanup () const { return false ; }
10731073
1074- AllocaCommand::AllocaCommand (queue_impl *Queue, Requirement Req,
1074+ AllocaCommand::AllocaCommand (queue_impl *Queue, const Requirement & Req,
10751075 bool InitFromUserData,
10761076 AllocaCommandBase *LinkedAllocaCmd, bool IsConst)
1077- : AllocaCommandBase(CommandType::ALLOCA, Queue, std::move( Req) ,
1078- LinkedAllocaCmd, IsConst),
1077+ : AllocaCommandBase(CommandType::ALLOCA, Queue, Req, LinkedAllocaCmd ,
1078+ IsConst),
10791079 MInitFromUserData(InitFromUserData) {
10801080 // Node event must be created before the dependent edge is added to this
10811081 // node, so this call must be before the addDep() call.
@@ -1149,11 +1149,12 @@ void AllocaCommand::printDot(std::ostream &Stream) const {
11491149 }
11501150}
11511151
1152- AllocaSubBufCommand::AllocaSubBufCommand (queue_impl *Queue, Requirement Req,
1152+ AllocaSubBufCommand::AllocaSubBufCommand (queue_impl *Queue,
1153+ const Requirement &Req,
11531154 AllocaCommandBase *ParentAlloca,
11541155 std::vector<Command *> &ToEnqueue,
11551156 std::vector<Command *> &ToCleanUp)
1156- : AllocaCommandBase(CommandType::ALLOCA_SUB_BUF, Queue, std::move( Req) ,
1157+ : AllocaCommandBase(CommandType::ALLOCA_SUB_BUF, Queue, Req,
11571158 /* LinkedAllocaCmd*/ nullptr , /* IsConst*/ false ),
11581159 MParentAlloca(ParentAlloca) {
11591160 // Node event must be created before the dependent edge
@@ -1358,11 +1359,11 @@ bool ReleaseCommand::supportsPostEnqueueCleanup() const { return false; }
13581359
13591360bool ReleaseCommand::readyForCleanup () const { return false ; }
13601361
1361- MapMemObject::MapMemObject (AllocaCommandBase *SrcAllocaCmd, Requirement Req,
1362- void **DstPtr, queue_impl *Queue ,
1363- access::mode MapMode)
1362+ MapMemObject::MapMemObject (AllocaCommandBase *SrcAllocaCmd,
1363+ const Requirement &Req, void **DstPtr ,
1364+ queue_impl *Queue, access::mode MapMode)
13641365 : Command(CommandType::MAP_MEM_OBJ, Queue), MSrcAllocaCmd(SrcAllocaCmd),
1365- MSrcReq(std::move( Req) ), MDstPtr(DstPtr), MMapMode(MapMode) {
1366+ MSrcReq(Req), MDstPtr(DstPtr), MMapMode(MapMode) {
13661367 emitInstrumentationDataProxy ();
13671368}
13681369
@@ -1421,10 +1422,11 @@ void MapMemObject::printDot(std::ostream &Stream) const {
14211422 }
14221423}
14231424
1424- UnMapMemObject::UnMapMemObject (AllocaCommandBase *DstAllocaCmd, Requirement Req,
1425- void **SrcPtr, queue_impl *Queue)
1425+ UnMapMemObject::UnMapMemObject (AllocaCommandBase *DstAllocaCmd,
1426+ const Requirement &Req, void **SrcPtr,
1427+ queue_impl *Queue)
14261428 : Command(CommandType::UNMAP_MEM_OBJ, Queue), MDstAllocaCmd(DstAllocaCmd),
1427- MDstReq(std::move( Req) ), MSrcPtr(SrcPtr) {
1429+ MDstReq(Req), MSrcPtr(SrcPtr) {
14281430 emitInstrumentationDataProxy ();
14291431}
14301432
@@ -1504,9 +1506,9 @@ void UnMapMemObject::printDot(std::ostream &Stream) const {
15041506 }
15051507}
15061508
1507- MemCpyCommand::MemCpyCommand (Requirement SrcReq,
1509+ MemCpyCommand::MemCpyCommand (const Requirement & SrcReq,
15081510 AllocaCommandBase *SrcAllocaCmd,
1509- Requirement DstReq,
1511+ const Requirement & DstReq,
15101512 AllocaCommandBase *DstAllocaCmd,
15111513 queue_impl *SrcQueue, queue_impl *DstQueue)
15121514 : Command(CommandType::COPY_MEMORY, DstQueue),
@@ -1678,14 +1680,14 @@ void UpdateHostRequirementCommand::printDot(std::ostream &Stream) const {
16781680 }
16791681}
16801682
1681- MemCpyCommandHost::MemCpyCommandHost (Requirement SrcReq,
1683+ MemCpyCommandHost::MemCpyCommandHost (const Requirement & SrcReq,
16821684 AllocaCommandBase *SrcAllocaCmd,
1683- Requirement DstReq, void **DstPtr,
1685+ const Requirement & DstReq, void **DstPtr,
16841686 queue_impl *SrcQueue, queue_impl *DstQueue)
16851687 : Command(CommandType::COPY_MEMORY, DstQueue),
16861688 MSrcQueue(SrcQueue ? SrcQueue->shared_from_this () : nullptr),
1687- MSrcReq(std::move( SrcReq)) , MSrcAllocaCmd(SrcAllocaCmd),
1688- MDstReq(std::move(DstReq)), MDstPtr(DstPtr) {
1689+ MSrcReq(SrcReq), MSrcAllocaCmd(SrcAllocaCmd), MDstReq(DstReq ),
1690+ MDstPtr(DstPtr) {
16891691 if (MSrcQueue) {
16901692 MEvent->setContextImpl (MSrcQueue->getContextImpl ());
16911693 }
@@ -1850,10 +1852,10 @@ void MemCpyCommandHost::printDot(std::ostream &Stream) const {
18501852}
18511853
18521854UpdateHostRequirementCommand::UpdateHostRequirementCommand (
1853- queue_impl *Queue, Requirement Req, AllocaCommandBase *SrcAllocaCmd,
1855+ queue_impl *Queue, const Requirement & Req, AllocaCommandBase *SrcAllocaCmd,
18541856 void **DstPtr)
18551857 : Command(CommandType::UPDATE_REQUIREMENT, Queue),
1856- MSrcAllocaCmd(SrcAllocaCmd), MDstReq(std::move( Req) ), MDstPtr(DstPtr) {
1858+ MSrcAllocaCmd(SrcAllocaCmd), MDstReq(Req), MDstPtr(DstPtr) {
18571859
18581860 emitInstrumentationDataProxy ();
18591861}
0 commit comments