From 90b3913451cbac61fbd708edd06bfb10b8158e87 Mon Sep 17 00:00:00 2001 From: foreman Date: Wed, 4 Apr 2018 18:08:54 -0400 Subject: [PATCH] P4 to Git Change 1536943 by vsytchen@vsytchen-ocl-win10 on 2018/04/04 17:50:57 SWDEV-79445 - OCL generic changes and code clean-up Fix ocl build Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/platform/command.cpp#82 edit --- rocclr/runtime/platform/command.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rocclr/runtime/platform/command.cpp b/rocclr/runtime/platform/command.cpp index 2363ce3853..6e53636526 100644 --- a/rocclr/runtime/platform/command.cpp +++ b/rocclr/runtime/platform/command.cpp @@ -468,10 +468,10 @@ bool MakeBuffersResidentCommand::validateMemory() { } bool ThreadTraceMemObjectsCommand::validateMemory() { if (queue()->device().info().type_ & CL_DEVICE_TYPE_GPU) { - for (auto& it = memObjects_.cbegin(); it != memObjects_.cend(); it++) { + for (auto it = memObjects_.cbegin(); it != memObjects_.cend(); it++) { device::Memory* mem = (*it)->getDeviceMemory(queue()->device()); if (NULL == mem) { - for (auto& tmpIt = memObjects_.cbegin(); tmpIt != it; tmpIt++) { + for (auto tmpIt = memObjects_.cbegin(); tmpIt != it; tmpIt++) { device::Memory* tmpMem = (*tmpIt)->getDeviceMemory(queue()->device()); delete tmpMem; }