Conditional tweak in the nonbonded GPU kernels
commit2aa05015eeb6d3352d0871958a7903ecb2fabd8d
authorSzilárd Páll <pall.szilard@gmail.com>
Sun, 19 Mar 2017 23:47:32 +0000 (20 00:47 +0100)
committerAleksei Iupinov <a.yupinov@gmail.com>
Sat, 25 Mar 2017 09:56:53 +0000 (25 10:56 +0100)
tree03a29c6d1814676ab06b6f0eff5b6cb3e5fab186
parenta1bffbe185c573ee113da97a30290fa89dea9fd1
Conditional tweak in the nonbonded GPU kernels

GPU compilers miss an easy optimization of a loop invariant in the
inner-lop conditional. Precomputing part of the conditional together
with using bitwise instead of logical and/or improves performance with
most compilers by up to 5%.

Change-Id: I3ba0b9025b11af3d8465e0d26ca69a78e32a0ece
src/gromacs/mdlib/nbnxn_cuda/nbnxn_cuda_kernel.cuh
src/gromacs/mdlib/nbnxn_cuda/nbnxn_cuda_kernel_fermi.cuh
src/gromacs/mdlib/nbnxn_ocl/nbnxn_ocl_kernel_amd.clh
src/gromacs/mdlib/nbnxn_ocl/nbnxn_ocl_kernel_nowarp.clh
src/gromacs/mdlib/nbnxn_ocl/nbnxn_ocl_kernel_nvidia.clh