Fix load balancing issue with 2D FFTs

This commit is contained in:
Nick Hagerty
2024-04-23 13:42:46 -04:00
parent 5c5dd1efb4
commit f9e349a2bc

View File

@ -1389,10 +1389,7 @@ void PPPM::set_grid_local()
// of the global FFT mesh that I own in x-pencil decomposition
int npey_fft,npez_fft;
if (nz_pppm >= nprocs) {
npey_fft = 1;
npez_fft = nprocs;
} else procs2grid2d(nprocs,ny_pppm,nz_pppm,&npey_fft,&npez_fft);
procs2grid2d(nprocs,ny_pppm,nz_pppm,&npey_fft,&npez_fft);
int me_y = me % npey_fft;
int me_z = me / npey_fft;