Commit 5971d4c9 authored by sjplimp's avatar sjplimp Committed by GitHub
Browse files

Merge pull request #358 from ibaned/warnings

warning fixes (Kokkos+CUDA)
parents 868d95f0 672bbbe4
Loading
Loading
Loading
Loading
+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)
+3 −3
Original line number Diff line number Diff line
@@ -147,9 +147,9 @@ void NeighborKokkos::init_ex_mol_bit_kokkos()
int NeighborKokkos::check_distance()
{
  if (device_flag)
    check_distance_kokkos<LMPDeviceType>();
    return check_distance_kokkos<LMPDeviceType>();
  else
    check_distance_kokkos<LMPHostType>();
    return check_distance_kokkos<LMPHostType>();
}

template<class DeviceType>
@@ -157,7 +157,7 @@ int NeighborKokkos::check_distance_kokkos()
{
  typedef DeviceType device_type;

  double delx,dely,delz,rsq;
  double delx,dely,delz;
  double delta,delta1,delta2;

  if (boxcheck) {
+2 −0
Original line number Diff line number Diff line
@@ -44,7 +44,9 @@ class PairBuckCoulCutKokkos : public PairBuckCoulCut {
  double init_one(int, int);

  struct params_buck_coul{
    KOKKOS_INLINE_FUNCTION
    params_buck_coul(){cut_ljsq=0;cut_coulsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    KOKKOS_INLINE_FUNCTION
    params_buck_coul(int i){cut_ljsq=0;cut_coulsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    F_FLOAT cut_ljsq,cut_coulsq,a,c,rhoinv,buck1,buck2,offset;
  };
+2 −0
Original line number Diff line number Diff line
@@ -45,7 +45,9 @@ class PairBuckCoulLongKokkos : public PairBuckCoulLong {
  double init_one(int, int);

  struct params_buck_coul{
    KOKKOS_INLINE_FUNCTION
    params_buck_coul(){cut_ljsq=0;cut_coulsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    KOKKOS_INLINE_FUNCTION
    params_buck_coul(int i){cut_ljsq=0;cut_coulsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    F_FLOAT cut_ljsq,cut_coulsq,a,c,rhoinv,buck1,buck2,offset;
  };
+2 −0
Original line number Diff line number Diff line
@@ -43,7 +43,9 @@ class PairBuckKokkos : public PairBuck {
  double init_one(int, int);

  struct params_buck{
    KOKKOS_INLINE_FUNCTION
    params_buck(){cutsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    KOKKOS_INLINE_FUNCTION
    params_buck(int i){cutsq=0;a=0;c=0;rhoinv=0;buck1=0;buck2=0;offset=0;};
    F_FLOAT cutsq,a,c,rhoinv,buck1,buck2,offset;
  };
Loading