39 maxNeighbors(initsize), maxAtoms(initsize),
40 curNeighbor(0), curAtom(0) {
42 nnfa =
new int[initsize];
50 int reqNewSize = curNeighbor + max_size;
51 int newSize = maxNeighbors;
52 while ( newSize < reqNewSize ) { newSize += newSize >> 1; }
53 if ( newSize > maxNeighbors ) {
55 CmiMemcpy(newNeighbors,neighbors,curNeighbor*
sizeof(
LCPOAtom));
57 neighbors = newNeighbors;
58 maxNeighbors = newSize;
61 if (curAtom == maxAtoms) {
62 newSize = maxAtoms + (maxAtoms >> 1);
63 int *newNnfa =
new int[newSize];
64 CmiMemcpy(newNnfa,nnfa,curAtom*
sizeof(
int));
69 return &neighbors[curNeighbor];
73 return &neighbors[curNeighbor];
76 nnfa[curAtom] = list_size;
78 curNeighbor += list_size;
85 *list = &neighbors[curNeighbor];
86 *list_size = nnfa[curAtom];
87 curNeighbor += nnfa[curAtom];
105 int minPartition,
int maxPartition,
int numPartitions,
int numPatches);
154 static const Real lcpoParams[23][5];
Box< Patch, int > * lcpoTypeBox[8]
ComputeNonbondedWorkArrays *const workArrays
Box< Patch, Results > * forceBox[8]
virtual void atomUpdate()
virtual void initialize()
void newsize(int list_size)
Box< Patch, CompAtom > * positionBox[8]
LCPOAtom * newlist(int max_size)
ComputeLCPO(ComputeID c, PatchID pid[], int t[], ComputeNonbondedWorkArrays *_workArrays, int minPartition, int maxPartition, int numPartitions, int numPatches)
void nextlist(LCPOAtom **list, int *list_size)
SubmitReduction * reduction