Skip to content
Snippets Groups Projects
Commit 01c27194 authored by Trung Nguyen's avatar Trung Nguyen
Browse files

Fixes for lal_neighbor.cpp for get_host() and for time_kernel

parent 223de574
No related branches found
No related tags found
No related merge requests found
...@@ -281,7 +281,7 @@ void Neighbor::get_host(const int inum, int *ilist, int *numj, ...@@ -281,7 +281,7 @@ void Neighbor::get_host(const int inum, int *ilist, int *numj,
} }
UCL_D_Vec<int> acc_view; UCL_D_Vec<int> acc_view;
acc_view.view_offset(inum,dev_nbor,inum*2); acc_view.view_offset(inum,dev_nbor,inum*2);
ucl_copy(acc_view,host_acc,true); ucl_copy(acc_view,host_acc,inum*2,true);
UCL_H_Vec<int> host_view; UCL_H_Vec<int> host_view;
host_view.alloc(_max_atoms,*dev,UCL_READ_WRITE); host_view.alloc(_max_atoms,*dev,UCL_READ_WRITE);
...@@ -364,7 +364,7 @@ void Neighbor::get_host3(const int inum, const int nlist, int *ilist, int *numj, ...@@ -364,7 +364,7 @@ void Neighbor::get_host3(const int inum, const int nlist, int *ilist, int *numj,
} }
UCL_D_Vec<int> acc_view; UCL_D_Vec<int> acc_view;
acc_view.view_offset(inum,dev_nbor,inum*2); acc_view.view_offset(inum,dev_nbor,inum*2);
ucl_copy(acc_view,host_acc,true); ucl_copy(acc_view,host_acc,inum*2,true);
time_nbor.stop(); time_nbor.stop();
if (_use_packing==false) { if (_use_packing==false) {
......
...@@ -110,7 +110,7 @@ class Neighbor { ...@@ -110,7 +110,7 @@ class Neighbor {
} }
if (_time_device) { if (_time_device) {
time_nbor.add_to_total(); time_nbor.add_to_total();
time_kernel.add_to_total(); if (_use_packing==false) time_kernel.add_to_total();
if (_gpu_nbor==2) { if (_gpu_nbor==2) {
time_hybrid1.add_to_total(); time_hybrid1.add_to_total();
time_hybrid2.add_to_total(); time_hybrid2.add_to_total();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment