remove dead code to silence compiler warnings
This commit is contained in:
@ -825,8 +825,6 @@ void PPPMDispIntel::make_rho_c(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
// (dx,dy,dz) = distance to "lower left" grid pt
|
||||
// (mx,my,mz) = global coords of moving stencil pt
|
||||
|
||||
//double *q = atom->q;
|
||||
//double **x = atom->x;
|
||||
int nlocal = atom->nlocal;
|
||||
int nthr = comm->nthreads;
|
||||
|
||||
@ -847,7 +845,6 @@ void PPPMDispIntel::make_rho_c(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
const flt_t xi = delxinv;
|
||||
const flt_t yi = delyinv;
|
||||
const flt_t zi = delzinv;
|
||||
const flt_t fshift = shift;
|
||||
const flt_t fshiftone = shiftone;
|
||||
const flt_t fdelvolinv = delvolinv;
|
||||
|
||||
@ -1011,7 +1008,6 @@ void PPPMDispIntel::make_rho_g(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
const flt_t xi = delxinv_6;
|
||||
const flt_t yi = delyinv_6;
|
||||
const flt_t zi = delzinv_6;
|
||||
const flt_t fshift = shift_6;
|
||||
const flt_t fshiftone = shiftone_6;
|
||||
const flt_t fdelvolinv = delvolinv_6;
|
||||
|
||||
@ -1150,20 +1146,13 @@ void PPPMDispIntel::make_rho_a(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
{
|
||||
// clear 3d density array
|
||||
|
||||
memset(&(density_brick_a0[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a1[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a2[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a3[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a4[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a5[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a6[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,
|
||||
ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a0[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a1[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a2[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a3[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a4[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a5[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
memset(&(density_brick_a6[nzlo_out_6][nylo_out_6][nxlo_out_6]),0,ngrid_6*sizeof(FFT_SCALAR));
|
||||
|
||||
// loop over my charges, add their contribution to nearby grid points
|
||||
// (nx,ny,nz) = global coords of grid pt to "lower left" of charge
|
||||
@ -1171,117 +1160,112 @@ void PPPMDispIntel::make_rho_a(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
// (mx,my,mz) = global coords of moving stencil pt
|
||||
|
||||
int nlocal = atom->nlocal;
|
||||
double **x = atom->x;
|
||||
|
||||
double **x = atom->x;
|
||||
const flt_t lo0 = boxlo[0];
|
||||
const flt_t lo1 = boxlo[1];
|
||||
const flt_t lo2 = boxlo[2];
|
||||
const flt_t xi = delxinv_6;
|
||||
const flt_t yi = delyinv_6;
|
||||
const flt_t zi = delzinv_6;
|
||||
const flt_t fshiftone = shiftone_6;
|
||||
const flt_t fdelvolinv = delvolinv_6;
|
||||
|
||||
const int nix = nxhi_out_6 - nxlo_out_6 + 1;
|
||||
const int niy = nyhi_out_6 - nylo_out_6 + 1;
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
|
||||
const flt_t lo0 = boxlo[0];
|
||||
const flt_t lo1 = boxlo[1];
|
||||
const flt_t lo2 = boxlo[2];
|
||||
const flt_t xi = delxinv_6;
|
||||
const flt_t yi = delyinv_6;
|
||||
const flt_t zi = delzinv_6;
|
||||
const flt_t fshift = shift_6;
|
||||
const flt_t fshiftone = shiftone_6;
|
||||
const flt_t fdelvolinv = delvolinv_6;
|
||||
int nx = part2grid_6[i][0];
|
||||
int ny = part2grid_6[i][1];
|
||||
int nz = part2grid_6[i][2];
|
||||
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
int nxsum = nx + nlower_6;
|
||||
int nysum = ny + nlower_6;
|
||||
int nzsum = nz + nlower_6;
|
||||
|
||||
int nx = part2grid_6[i][0];
|
||||
int ny = part2grid_6[i][1];
|
||||
int nz = part2grid_6[i][2];
|
||||
FFT_SCALAR dx = nx+fshiftone - (x[i][0]-lo0)*xi;
|
||||
FFT_SCALAR dy = ny+fshiftone - (x[i][1]-lo1)*yi;
|
||||
FFT_SCALAR dz = nz+fshiftone - (x[i][2]-lo2)*zi;
|
||||
|
||||
int nxsum = nx + nlower_6;
|
||||
int nysum = ny + nlower_6;
|
||||
int nzsum = nz + nlower_6;
|
||||
_alignvar(flt_t rho[3][INTEL_P3M_ALIGNED_MAXORDER], 64) = {0};
|
||||
|
||||
FFT_SCALAR dx = nx+fshiftone - (x[i][0]-lo0)*xi;
|
||||
FFT_SCALAR dy = ny+fshiftone - (x[i][1]-lo1)*yi;
|
||||
FFT_SCALAR dz = nz+fshiftone - (x[i][2]-lo2)*zi;
|
||||
|
||||
_alignvar(flt_t rho[3][INTEL_P3M_ALIGNED_MAXORDER], 64) = {0};
|
||||
|
||||
if (use_table) {
|
||||
dx = dx*half_rho_scale + half_rho_scale_plus;
|
||||
int idx = dx;
|
||||
dy = dy*half_rho_scale + half_rho_scale_plus;
|
||||
int idy = dy;
|
||||
dz = dz*half_rho_scale + half_rho_scale_plus;
|
||||
int idz = dz;
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
if (use_table) {
|
||||
dx = dx*half_rho_scale + half_rho_scale_plus;
|
||||
int idx = dx;
|
||||
dy = dy*half_rho_scale + half_rho_scale_plus;
|
||||
int idy = dy;
|
||||
dz = dz*half_rho_scale + half_rho_scale_plus;
|
||||
int idz = dz;
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#if defined(USE_OMP_SIMD)
|
||||
#pragma omp simd
|
||||
#pragma omp simd
|
||||
#else
|
||||
#pragma simd
|
||||
#pragma simd
|
||||
#endif
|
||||
#endif
|
||||
for (int k = 0; k < INTEL_P3M_ALIGNED_MAXORDER; k++) {
|
||||
rho[0][k] = rho6_lookup[idx][k];
|
||||
rho[1][k] = rho6_lookup[idy][k];
|
||||
rho[2][k] = rho6_lookup[idz][k];
|
||||
}
|
||||
} else {
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#if defined(USE_OMP_SIMD)
|
||||
#pragma omp simd
|
||||
#else
|
||||
#pragma simd
|
||||
#endif
|
||||
#endif
|
||||
for (int k = nlower_6; k <= nupper_6; k++) {
|
||||
FFT_SCALAR r1,r2,r3;
|
||||
r1 = r2 = r3 = ZEROF;
|
||||
|
||||
for (int l = order_6-1; l >= 0; l--) {
|
||||
r1 = rho_coeff_6[l][k] + r1*dx;
|
||||
r2 = rho_coeff_6[l][k] + r2*dy;
|
||||
r3 = rho_coeff_6[l][k] + r3*dz;
|
||||
}
|
||||
rho[0][k-nlower_6] = r1;
|
||||
rho[1][k-nlower_6] = r2;
|
||||
rho[2][k-nlower_6] = r3;
|
||||
}
|
||||
for (int k = 0; k < INTEL_P3M_ALIGNED_MAXORDER; k++) {
|
||||
rho[0][k] = rho6_lookup[idx][k];
|
||||
rho[1][k] = rho6_lookup[idy][k];
|
||||
rho[2][k] = rho6_lookup[idz][k];
|
||||
}
|
||||
|
||||
const int type = atom->type[i];
|
||||
FFT_SCALAR z0 = fdelvolinv;
|
||||
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int n = 0; n < order_6; n++) {
|
||||
int mz = n + nzsum;
|
||||
FFT_SCALAR y0 = z0*rho[2][n];
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int m = 0; m < order_6; m++) {
|
||||
int my = m + nysum;
|
||||
FFT_SCALAR x0 = y0*rho[1][m];
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
} else {
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#if defined(USE_OMP_SIMD)
|
||||
#pragma omp simd
|
||||
#pragma omp simd
|
||||
#else
|
||||
#pragma simd
|
||||
#pragma simd
|
||||
#endif
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int l = 0; l < order; l++) {
|
||||
int mx = l + nxsum;
|
||||
FFT_SCALAR w = x0*rho[0][l];
|
||||
density_brick_a0[mz][my][mx] += w*B[7*type];
|
||||
density_brick_a1[mz][my][mx] += w*B[7*type+1];
|
||||
density_brick_a2[mz][my][mx] += w*B[7*type+2];
|
||||
density_brick_a3[mz][my][mx] += w*B[7*type+3];
|
||||
density_brick_a4[mz][my][mx] += w*B[7*type+4];
|
||||
density_brick_a5[mz][my][mx] += w*B[7*type+5];
|
||||
density_brick_a6[mz][my][mx] += w*B[7*type+6];
|
||||
}
|
||||
#endif
|
||||
for (int k = nlower_6; k <= nupper_6; k++) {
|
||||
FFT_SCALAR r1,r2,r3;
|
||||
r1 = r2 = r3 = ZEROF;
|
||||
|
||||
for (int l = order_6-1; l >= 0; l--) {
|
||||
r1 = rho_coeff_6[l][k] + r1*dx;
|
||||
r2 = rho_coeff_6[l][k] + r2*dy;
|
||||
r3 = rho_coeff_6[l][k] + r3*dz;
|
||||
}
|
||||
rho[0][k-nlower_6] = r1;
|
||||
rho[1][k-nlower_6] = r2;
|
||||
rho[2][k-nlower_6] = r3;
|
||||
}
|
||||
}
|
||||
|
||||
const int type = atom->type[i];
|
||||
FFT_SCALAR z0 = fdelvolinv;
|
||||
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int n = 0; n < order_6; n++) {
|
||||
int mz = n + nzsum;
|
||||
FFT_SCALAR y0 = z0*rho[2][n];
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int m = 0; m < order_6; m++) {
|
||||
int my = m + nysum;
|
||||
FFT_SCALAR x0 = y0*rho[1][m];
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
#if defined(USE_OMP_SIMD)
|
||||
#pragma omp simd
|
||||
#else
|
||||
#pragma simd
|
||||
#endif
|
||||
#pragma loop_count min(2), max(INTEL_P3M_ALIGNED_MAXORDER), avg(7)
|
||||
#endif
|
||||
for (int l = 0; l < order; l++) {
|
||||
int mx = l + nxsum;
|
||||
FFT_SCALAR w = x0*rho[0][l];
|
||||
density_brick_a0[mz][my][mx] += w*B[7*type];
|
||||
density_brick_a1[mz][my][mx] += w*B[7*type+1];
|
||||
density_brick_a2[mz][my][mx] += w*B[7*type+2];
|
||||
density_brick_a3[mz][my][mx] += w*B[7*type+3];
|
||||
density_brick_a4[mz][my][mx] += w*B[7*type+4];
|
||||
density_brick_a5[mz][my][mx] += w*B[7*type+5];
|
||||
density_brick_a6[mz][my][mx] += w*B[7*type+6];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* ----------------------------------------------------------------------
|
||||
@ -1310,7 +1294,6 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
shared(nthr, nlocal, global_density) if (!_use_lrt)
|
||||
#endif
|
||||
{
|
||||
int type;
|
||||
double **x = atom->x;
|
||||
|
||||
const int nix = nxhi_out_6 - nxlo_out_6 + 1;
|
||||
@ -1322,7 +1305,6 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
const flt_t xi = delxinv_6;
|
||||
const flt_t yi = delyinv_6;
|
||||
const flt_t zi = delzinv_6;
|
||||
const flt_t fshift = shift_6;
|
||||
const flt_t fshiftone = shiftone_6;
|
||||
const flt_t fdelvolinv = delvolinv_6;
|
||||
|
||||
@ -1391,7 +1373,6 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
}
|
||||
}
|
||||
|
||||
type = atom->type[i];
|
||||
FFT_SCALAR z0 = fdelvolinv;
|
||||
|
||||
#if defined(LMP_SIMD_COMPILER)
|
||||
@ -1416,7 +1397,6 @@ void PPPMDispIntel::make_rho_none(IntelBuffers<flt_t,acc_t> * /*buffers*/)
|
||||
#endif
|
||||
for (int l = 0; l < order; l++) {
|
||||
int mzyx = l + mzy;
|
||||
FFT_SCALAR w0 = x0*rho[0][l];
|
||||
for (int k = 0; k < nsplit; k++)
|
||||
my_density[mzyx + k*ngrid_6] += x0*rho[0][l];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user