From 104373b492e63c5a1aecba179c456153b92f4ca3 Mon Sep 17 00:00:00 2001 From: Berk Hess Date: Fri, 15 Nov 2013 15:51:36 +0100 Subject: [PATCH] corrected potential nbnxn SIMD memory issue A fixed size array on the stack was declared with one element too few. Probably this never caused trouble with 64-bit builds, but it might have caused trouble with 32-bit builds. Change-Id: I4dad0a7a9e80f5d27ac6ee7e4383082db654481a --- .../simd_4xn/nbnxn_kernel_simd_4xn_outer.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/mdlib/nbnxn_kernels/simd_4xn/nbnxn_kernel_simd_4xn_outer.h b/src/mdlib/nbnxn_kernels/simd_4xn/nbnxn_kernel_simd_4xn_outer.h index 2fe56cf5b3..b306733a27 100644 --- a/src/mdlib/nbnxn_kernels/simd_4xn/nbnxn_kernel_simd_4xn_outer.h +++ b/src/mdlib/nbnxn_kernels/simd_4xn/nbnxn_kernel_simd_4xn_outer.h @@ -120,12 +120,12 @@ const real *tab_coul_V; #endif /* Thread-local working buffers for force and potential lookups */ - int ti0_array[2*GMX_SIMD_WIDTH_HERE-1], *ti0 = NULL; - int ti1_array[2*GMX_SIMD_WIDTH_HERE-1], *ti1 = NULL; - int ti2_array[2*GMX_SIMD_WIDTH_HERE-1], *ti2 = NULL; - int ti3_array[2*GMX_SIMD_WIDTH_HERE-1], *ti3 = NULL; + int ti0_array[2*GMX_SIMD_WIDTH_HERE], *ti0 = NULL; + int ti1_array[2*GMX_SIMD_WIDTH_HERE], *ti1 = NULL; + int ti2_array[2*GMX_SIMD_WIDTH_HERE], *ti2 = NULL; + int ti3_array[2*GMX_SIMD_WIDTH_HERE], *ti3 = NULL; #ifdef CALC_ENERGIES - gmx_mm_pr mhalfsp_S; + gmx_mm_pr mhalfsp_S; #endif #endif -- 2.22.0