git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@14835 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -441,7 +441,7 @@ ComputeChunkAtom::ComputeChunkAtom(LAMMPS *lmp, int narg, char **arg) :
|
||||
|
||||
nmax = 0;
|
||||
chunk = NULL;
|
||||
nmaxint = 0;
|
||||
nmaxint = -1;
|
||||
ichunk = NULL;
|
||||
exclude = NULL;
|
||||
|
||||
@ -1989,7 +1989,7 @@ void ComputeChunkAtom::set_arrays(int i)
|
||||
|
||||
double ComputeChunkAtom::memory_usage()
|
||||
{
|
||||
double bytes = 2*nmaxint * sizeof(int); // ichunk,exclude
|
||||
double bytes = 2*MAX(nmaxint,0) * sizeof(int); // ichunk,exclude
|
||||
bytes += nmax * sizeof(double); // chunk
|
||||
bytes += ncoord*nchunk * sizeof(double); // coord
|
||||
if (compress) bytes += nchunk * sizeof(int); // chunkID
|
||||
|
||||
Reference in New Issue
Block a user