Commit ed0a347f authored by Oliver Henrich's avatar Oliver Henrich
Browse files

Merge branch 'master' into user-cgdna

parents 149f37e7 f8506fee
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
<!-- HTML_ONLY -->
<HEAD>
<TITLE>LAMMPS Users Manual</TITLE>
<META NAME="docnumber" CONTENT="20 Jan 2017 version">
<META NAME="docnumber" CONTENT="26 Jan 2017 version">
<META NAME="author" CONTENT="http://lammps.sandia.gov - Sandia National Laboratories">
<META NAME="copyright" CONTENT="Copyright (2003) Sandia Corporation.  This software and manual is distributed under the GNU General Public License.">
</HEAD>
@@ -21,7 +21,7 @@
<H1></H1>

LAMMPS Documentation :c,h3
20 Jan 2017 version :c,h4
26 Jan 2017 version :c,h4

Version info: :h4

potentials/WL.meam

0 → 100644
+13 −0
Original line number Diff line number Diff line
# DATE: 2017-01-25 CONTRIBUTOR: Aidan Thompson, athomps@sandia.gov,  CITATION: Lee, Baskes, Kim, Cho. Phys. Rev. B, 64, 184102 (2001) 
rc = 3.8
delr = 0.1
augt1 = 0
erose_form = 2
zbl(1,1) = 0
nn2(1,1) = 1
Ec(1,1) = 8.66
re(1,1) = 2.74
attrac(1,1) = 0
repuls(1,1) = 0
Cmin(1,1,1) = 0.49
Cmax(1,1,1) = 2.8
+8 −4
Original line number Diff line number Diff line
@@ -402,7 +402,6 @@ void DomainKokkos::pbc()
void DomainKokkos::remap_all()
{
  atomKK->sync(Device,X_MASK | IMAGE_MASK);
  atomKK->modified(Device,X_MASK | IMAGE_MASK);

  x = atomKK->k_x.view<LMPDeviceType>();
  image = atomKK->k_image.view<LMPDeviceType>();
@@ -428,6 +427,8 @@ void DomainKokkos::remap_all()
  LMPDeviceType::fence();
  copymode = 0;

  atomKK->modified(Device,X_MASK | IMAGE_MASK);

  if (triclinic) lamda2x(nlocal);
}

@@ -521,7 +522,6 @@ void DomainKokkos::image_flip(int m_in, int n_in, int p_in)
  p_flip = p_in;

  atomKK->sync(Device,IMAGE_MASK);
  atomKK->modified(Device,IMAGE_MASK);

  image = atomKK->k_image.view<LMPDeviceType>();
  int nlocal = atomKK->nlocal;
@@ -530,6 +530,8 @@ void DomainKokkos::image_flip(int m_in, int n_in, int p_in)
  Kokkos::parallel_for(Kokkos::RangePolicy<LMPDeviceType, TagDomain_image_flip>(0,nlocal),*this);
  LMPDeviceType::fence();
  copymode = 0;

  atomKK->modified(Device,IMAGE_MASK);
}

KOKKOS_INLINE_FUNCTION
@@ -554,7 +556,6 @@ void DomainKokkos::operator()(TagDomain_image_flip, const int &i) const {
void DomainKokkos::lamda2x(int n)
{
  atomKK->sync(Device,X_MASK);
  atomKK->modified(Device,X_MASK);

  x = atomKK->k_x.view<LMPDeviceType>();

@@ -562,6 +563,8 @@ void DomainKokkos::lamda2x(int n)
  Kokkos::parallel_for(Kokkos::RangePolicy<LMPDeviceType, TagDomain_lamda2x>(0,n),*this);
  LMPDeviceType::fence();
  copymode = 0;

  atomKK->modified(Device,X_MASK);
}

KOKKOS_INLINE_FUNCTION
@@ -579,7 +582,6 @@ void DomainKokkos::operator()(TagDomain_lamda2x, const int &i) const {
void DomainKokkos::x2lamda(int n)
{
  atomKK->sync(Device,X_MASK);
  atomKK->modified(Device,X_MASK);

  x = atomKK->k_x.view<LMPDeviceType>();

@@ -587,6 +589,8 @@ void DomainKokkos::x2lamda(int n)
  Kokkos::parallel_for(Kokkos::RangePolicy<LMPDeviceType, TagDomain_x2lamda>(0,n),*this);
  LMPDeviceType::fence();
  copymode = 0;

  atomKK->modified(Device,X_MASK);
}

KOKKOS_INLINE_FUNCTION
+6 −3
Original line number Diff line number Diff line
@@ -177,11 +177,12 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)

  // account for bias velocity
  if(tbiasflag == BIAS){
    atomKK->sync(temperature->execution_space,temperature->datamask_read);
    temperature->compute_scalar();
    temperature->remove_bias_all(); // modifies velocities
    // if temeprature compute is kokkosized host-devcie comm won't be needed
    atomKK->modified(Host,V_MASK);
    atomKK->sync(execution_space,V_MASK);
    atomKK->modified(temperature->execution_space,temperature->datamask_modify);
    atomKK->sync(execution_space,temperature->datamask_modify);
  }

  // compute langevin force in parallel on the device
@@ -508,8 +509,10 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
  DeviceType::fence();

  if(tbiasflag == BIAS){
    atomKK->sync(temperature->execution_space,temperature->datamask_read);
    temperature->restore_bias_all(); // modifies velocities
    atomKK->modified(Host,V_MASK);
    atomKK->modified(temperature->execution_space,temperature->datamask_modify);
    atomKK->sync(execution_space,temperature->datamask_modify);
  }

  // set modify flags for the views modified in post_force functor
+3 −4
Original line number Diff line number Diff line
@@ -42,12 +42,11 @@ namespace MathSpecialKokkos {
  {
    x *= x;
    x *= 1.4426950408889634074; // log_2(e)
#if defined(__BYTE_ORDER__)
#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
#if defined(__BYTE_ORDER__) &&  __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
    return (x < 1023.0) ? exp2_x86(-x) : 0.0;
#endif
#endif
#else
    return (x < 1023.0) ? exp2(-x) : 0.0;
#endif
  }

  // x**2, use instead of pow(x,2.0)
Loading