Fix misc clang warnings
authorRoland Schulz <roland.schulz@intel.com>
Sat, 26 Jan 2019 08:42:00 +0000 (00:42 -0800)
committerPaul Bauer <paul.bauer.q@gmail.com>
Sat, 26 Jan 2019 12:10:47 +0000 (13:10 +0100)
Change-Id: Ie319e46fce8709d504171d4937de695f0a75a9b2

cmake/gmxManageLmfit.cmake
src/gromacs/correlationfunctions/tests/expfit.cpp
src/gromacs/mdlib/nbnxn_atomdata.cpp
src/gromacs/mdlib/nbnxn_kernels/simd_2xnn/nbnxn_kernel_simd_2xnn.h
src/gromacs/mdlib/nbnxn_kernels/simd_4xn/nbnxn_kernel_simd_4xn.h

index 1656feb3c2ceb32308b67114bbeb2a286f4df464..14cddf6f11f450776906a9d57c8e33b100ea341d 100644 (file)
@@ -66,7 +66,7 @@ function(gmx_manage_lmfit)
         # would not convey the right information.
         add_library(lmfit INTERFACE)
         target_sources(lmfit INTERFACE $<TARGET_OBJECTS:lmfit_objlib>)
-        target_include_directories(lmfit INTERFACE $<BUILD_INTERFACE:${BUNDLED_LMFIT_DIR}>)
+        target_include_directories(lmfit SYSTEM INTERFACE $<BUILD_INTERFACE:${BUNDLED_LMFIT_DIR}>)
         # Add the lmfit interface library to the libgromacs Export name, even though
         # we will not be installing any content.
         install(TARGETS lmfit EXPORT libgromacs)
index 55e49863c0e8e2ee20effecae0e2ec3bebf8f109..162123bc066d1c735d8a6b2cacad6aa2af42eff3 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * This file is part of the GROMACS molecular simulation package.
  *
- * Copyright (c) 2014,2015,2017,2018, by the GROMACS development team, led by
+ * Copyright (c) 2014,2015,2017,2018,2019, by the GROMACS development team, led by
  * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
  * and including many others, as listed in the AUTHORS file in the
  * top-level source directory and at http://www.gromacs.org.
@@ -105,8 +105,8 @@ class ExpfitTest : public ::testing::Test
                 ed.endTime_   = tempValues[0][ed.nrLines_-1];
                 for (int j = 0; j  < ed.nrLines_; j++)
                 {
-                    ed.x_.push_back((real)tempValues[0][j]);
-                    ed.y_.push_back((real)tempValues[1][j]);
+                    ed.x_.push_back(static_cast<real>(tempValues[0][j]));
+                    ed.y_.push_back(static_cast<real>(tempValues[1][j]));
                 }
                 data_.push_back(ed);
 
index 9238c07b234ad2a5ac294d52d5fbdcbc5df530db..6e97d4e3a6c83595f75c0e4f17df5a7252324648 100644 (file)
@@ -378,7 +378,7 @@ nbnxn_atomdata_t::SimdMasks::SimdMasks()
 #endif
     }
 
-    if (!GMX_SIMD_HAVE_LOGICAL && !GMX_SIMD_HAVE_INT32_LOGICAL)
+    if (!GMX_SIMD_HAVE_LOGICAL && !GMX_SIMD_HAVE_INT32_LOGICAL) // NOLINT(misc-redundant-expression)
     {
         // If the SIMD implementation has no bitwise logical operation support
         // whatsoever we cannot use the normal masking. Instead,
index 7ca628d94a2898c6326852b19debd5067fe0529b..2d7c1be97b607950546c81f7aeac868c30597cb8 100644 (file)
@@ -143,7 +143,7 @@ nbk_func_noener       nbnxn_kernel_ElecEwTwinCut_VdwLJEwCombGeom_F_2xnn;
  * The minor index of the array goes over both the LJ combination rules,
  * which is only supported by plain cut-off, and the LJ switch/PME functions.
  */
-p_nbk_func_noener nbnxn_kernel_noener_simd_2xnn[coulktNR][vdwktNR] =
+static p_nbk_func_noener nbnxn_kernel_noener_simd_2xnn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_F_2xnn,
@@ -187,7 +187,7 @@ p_nbk_func_noener nbnxn_kernel_noener_simd_2xnn[coulktNR][vdwktNR] =
     },
 };
 
-p_nbk_func_ener nbnxn_kernel_ener_simd_2xnn[coulktNR][vdwktNR] =
+static p_nbk_func_ener nbnxn_kernel_ener_simd_2xnn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_VF_2xnn,
@@ -231,7 +231,7 @@ p_nbk_func_ener nbnxn_kernel_ener_simd_2xnn[coulktNR][vdwktNR] =
     },
 };
 
-p_nbk_func_ener nbnxn_kernel_energrp_simd_2xnn[coulktNR][vdwktNR] =
+static p_nbk_func_ener nbnxn_kernel_energrp_simd_2xnn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_VgrpF_2xnn,
index 7e07a7c554290875a717e685eb96882a8412d004..78c9eeacb2945592af0ef39d659bf93090fddcb2 100644 (file)
@@ -143,7 +143,7 @@ nbk_func_noener       nbnxn_kernel_ElecEwTwinCut_VdwLJEwCombGeom_F_4xn;
  * The minor index of the array goes over both the LJ combination rules,
  * which is only supported by plain cut-off, and the LJ switch/PME functions.
  */
-p_nbk_func_noener nbnxn_kernel_noener_simd_4xn[coulktNR][vdwktNR] =
+static p_nbk_func_noener nbnxn_kernel_noener_simd_4xn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_F_4xn,
@@ -187,7 +187,7 @@ p_nbk_func_noener nbnxn_kernel_noener_simd_4xn[coulktNR][vdwktNR] =
     },
 };
 
-p_nbk_func_ener nbnxn_kernel_ener_simd_4xn[coulktNR][vdwktNR] =
+static p_nbk_func_ener nbnxn_kernel_ener_simd_4xn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_VF_4xn,
@@ -231,7 +231,7 @@ p_nbk_func_ener nbnxn_kernel_ener_simd_4xn[coulktNR][vdwktNR] =
     },
 };
 
-p_nbk_func_ener nbnxn_kernel_energrp_simd_4xn[coulktNR][vdwktNR] =
+static p_nbk_func_ener nbnxn_kernel_energrp_simd_4xn[coulktNR][vdwktNR] =
 {
     {
         nbnxn_kernel_ElecRF_VdwLJCombGeom_VgrpF_4xn,