lammps-master/lib/gpu/lal_atom.h
inline void add_v_data(double **host_ptr, tagint *host_tag) {
    time_vel.start();
    if (_v_avail==false) {
      #ifdef GPU_CAST
      v_cast.update_device(_nall*3,true);
      tag_cast.update_device(_nall,true);
      int block_size=64;
      int GX=static_cast<int>(ceil(static_cast<double>(_nall)/block_size));
      k_cast_x.set_size(GX,block_size);
      k_cast_x.run(&v, &v_cast, &tag_cast, &_nall);
      #else
      v.update_device(_nall*4,true);
      #endif
      _v_avail=true;
    }
    time_vel.stop();
  }
/// Copy velocities and tags to device asynchronously
/** Copies nall() elements **/
Copy velocities and tags to device asynchronously
Copies nall() elements
Copy velocities and tags to device asynchronously Copies nall () elements
inline void add_v_data(double **host_ptr, tagint *host_tag) {
    time_vel.start();
    if (_v_avail==false) {
      #ifdef GPU_CAST
      v_cast.update_device(_nall*3,true);
      tag_cast.update_device(_nall,true);
      int block_size=64;
      int GX=static_cast<int>(ceil(static_cast<double>(_nall)/block_size));
      k_cast_x.set_size(GX,block_size);
      k_cast_x.run(&v, &v_cast, &tag_cast, &_nall);
      #else
      v.update_device(_nall*4,true);
      #endif
      _v_avail=true;
    }
    time_vel.stop();
  }
inline void add_v_data ( double * * host_ptr , tagint * host_tag ) { time_vel . start ( ) ; if ( _v_avail == false ) { #ifdef GPU_CAST v_cast . update_device ( _nall * 3 , true ) ; tag_cast . update_device ( _nall , true ) ; int block_size = 64 ; int GX = static_cast < int > ( ceil ( static_cast < double > ( _nall ) / block_size ) ) ; k_cast_x . set_size ( GX , block_size ) ; k_cast_x . run ( & v , & v_cast , & tag_cast , & _nall ) ; #else v . update_device ( _nall * 4 , true ) ; #endif _v_avail = true ; } time_vel . stop ( ) ; }
Copy velocities and tags to device asynchronously
Copies nall() elements
Copy velocities and tags to device asynchronously Copies nall () elements