Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions src/Init/Init_FFTW.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -358,11 +358,13 @@ void Patch2Slab( real *VarS, real *SendBuf_Var, real *RecvBuf_Var, long *SendBuf
# endif // GAMER_DEBUG


const int SSize[2] = { ( InPlacePad ? 2*(FFT_Size[0]/2+1) : FFT_Size[0] ), FFT_Size[1] }; // padded slab size in the x and y directions
const int PSSize = PS1*PS1; // patch slice size
const int MemUnit = amr->NPatchComma[0][1]/MPI_NRank; // set arbitrarily; divided by MPI_NRank so that the memory consumption per rank for arrays
// like TempBuf_Var[MPI_NRank] reduces when launching more ranks
const int AveNz = FFT_Size[2]/MPI_NRank + ( ( FFT_Size[2]%MPI_NRank == 0 ) ? 0 : 1 ); // average slab thickness
const int SSize[2] = { ( InPlacePad ? 2*(FFT_Size[0]/2+1) : FFT_Size[0] ), FFT_Size[1] }; // padded slab size in the x and y directions
const int PSSize = PS1*PS1; // patch slice size
const int MemUnit = MAX( 1, amr->NPatchComma[0][1]/MPI_NRank ); // set arbitrarily; divided by MPI_NRank so that the
// memory consumption per rank for arrays like
// TempBuf_Var[MPI_NRank] reduces when launching
// more ranks
const int AveNz = FFT_Size[2]/MPI_NRank + ( ( FFT_Size[2]%MPI_NRank == 0 ) ? 0 : 1 ); // average slab thickness
const int Scale0 = amr->scale[0];

int Cr[3]; // corner coordinates of each patch normalized to the base-level grid size
Expand Down
Loading