Commit ed8f5ec4 authored by Diogo Martins's avatar Diogo Martins

issue #22 copy _next_ pointer if odd iter, _current_ if even

parent 8924a38a
......@@ -1102,8 +1102,15 @@ filled with clock() */
// ===============================================================================
//processing results
memcopyBufferObjectFromDevice(command_queue,cpu_final_populations,mem_dockpars_conformations_current,size_populations);
memcopyBufferObjectFromDevice(command_queue,cpu_energies,mem_dockpars_energies_current,size_energies);
if (generation_cnt % 2 == 0) {
memcopyBufferObjectFromDevice(command_queue,cpu_final_populations,mem_dockpars_conformations_current,size_populations);
memcopyBufferObjectFromDevice(command_queue,cpu_energies,mem_dockpars_energies_current,size_energies);
}
if (generation_cnt % 2 == 1) {
memcopyBufferObjectFromDevice(command_queue,cpu_final_populations,mem_dockpars_conformations_next,size_populations);
memcopyBufferObjectFromDevice(command_queue,cpu_energies,mem_dockpars_energies_next,size_energies);
}
#if defined (DOCK_DEBUG)
for (int cnt_pop=0;cnt_pop<size_populations/sizeof(float);cnt_pop++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment