Rename default directory to lammps and reorganize gromacs variant steps
Signed-off-by: Rafael Ravedutti <rafaelravedutti@gmail.com>
This commit is contained in:
parent
cbe42b8149
commit
aa0f4048d0
@ -1,7 +1,7 @@
|
|||||||
# Compiler tag (GCC/CLANG/ICC)
|
# Compiler tag (GCC/CLANG/ICC)
|
||||||
TAG ?= ICC
|
TAG ?= ICC
|
||||||
# Optimization scheme (default/gromacs/clusters_per_bin)
|
# Optimization scheme (lammps/gromacs/clusters_per_bin)
|
||||||
OPT_SCHEME = default
|
OPT_SCHEME = lammps
|
||||||
# Enable likwid (true or false)
|
# Enable likwid (true or false)
|
||||||
ENABLE_LIKWID ?= false
|
ENABLE_LIKWID ?= false
|
||||||
# SP or DP
|
# SP or DP
|
||||||
|
@ -39,4 +39,5 @@ extern void binatoms(Atom*);
|
|||||||
extern void buildNeighbor(Parameter*, Atom*, Neighbor*);
|
extern void buildNeighbor(Parameter*, Atom*, Neighbor*);
|
||||||
extern void sortAtom(Atom*);
|
extern void sortAtom(Atom*);
|
||||||
extern void buildClusters(Parameter*, Atom*);
|
extern void buildClusters(Parameter*, Atom*);
|
||||||
|
extern void binGhostClusters(Parameter*, Atom*);
|
||||||
#endif
|
#endif
|
||||||
|
@ -100,7 +100,7 @@ double setup(
|
|||||||
setupThermo(param, atom->Natoms);
|
setupThermo(param, atom->Natoms);
|
||||||
if(param->input_file == NULL) { adjustThermo(param, atom); }
|
if(param->input_file == NULL) { adjustThermo(param, atom); }
|
||||||
setupPbc(atom, param);
|
setupPbc(atom, param);
|
||||||
updatePbc(atom, param);
|
buildClusters(param, atom);
|
||||||
buildNeighbor(param, atom, neighbor);
|
buildNeighbor(param, atom, neighbor);
|
||||||
E = getTimeStamp();
|
E = getTimeStamp();
|
||||||
|
|
||||||
@ -118,8 +118,6 @@ double reneighbour(
|
|||||||
LIKWID_MARKER_START("reneighbour");
|
LIKWID_MARKER_START("reneighbour");
|
||||||
updateAtomsPbc(atom, param);
|
updateAtomsPbc(atom, param);
|
||||||
setupPbc(atom, param);
|
setupPbc(atom, param);
|
||||||
updatePbc(atom, param);
|
|
||||||
//sortAtom(atom);
|
|
||||||
buildNeighbor(param, atom, neighbor);
|
buildNeighbor(param, atom, neighbor);
|
||||||
LIKWID_MARKER_STOP("reneighbour");
|
LIKWID_MARKER_STOP("reneighbour");
|
||||||
E = getTimeStamp();
|
E = getTimeStamp();
|
||||||
|
@ -219,10 +219,6 @@ void buildNeighbor(Parameter *param, Atom *atom, Neighbor *neighbor) {
|
|||||||
neighbor->neighbors = (int*) malloc(nmax * neighbor->maxneighs * sizeof(int*));
|
neighbor->neighbors = (int*) malloc(nmax * neighbor->maxneighs * sizeof(int*));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* bin local & ghost atoms */
|
|
||||||
binatoms(atom);
|
|
||||||
buildClusters(param, atom);
|
|
||||||
|
|
||||||
const MD_FLOAT rBB = cutneighsq / 2.0; // TODO: change this
|
const MD_FLOAT rBB = cutneighsq / 2.0; // TODO: change this
|
||||||
int resize = 1;
|
int resize = 1;
|
||||||
|
|
||||||
@ -413,6 +409,9 @@ void sortBinAtomsByZCoord(Parameter *param, Atom *atom, int bin) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void buildClusters(Parameter *param, Atom *atom) {
|
void buildClusters(Parameter *param, Atom *atom) {
|
||||||
|
/* bin local atoms */
|
||||||
|
binatoms(atom);
|
||||||
|
|
||||||
for(int bin = 0; bin < mbins; bin++) {
|
for(int bin = 0; bin < mbins; bin++) {
|
||||||
sortBinAtomsByZCoord(param, atom, bin);
|
sortBinAtomsByZCoord(param, atom, bin);
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include <pbc.h>
|
#include <pbc.h>
|
||||||
#include <atom.h>
|
#include <atom.h>
|
||||||
#include <allocate.h>
|
#include <allocate.h>
|
||||||
|
#include <neighbor.h>
|
||||||
|
|
||||||
#define DELTA 20000
|
#define DELTA 20000
|
||||||
|
|
||||||
@ -177,4 +178,8 @@ void setupPbc(Atom *atom, Parameter *param) {
|
|||||||
// increase by one to make it the ghost atom count
|
// increase by one to make it the ghost atom count
|
||||||
atom->Nclusters_ghost = Nghost + 1;
|
atom->Nclusters_ghost = Nghost + 1;
|
||||||
atom->Nclusters = atom->Nclusters_local + Nghost + 1;
|
atom->Nclusters = atom->Nclusters_local + Nghost + 1;
|
||||||
|
|
||||||
|
// Update and bin created ghost clusters
|
||||||
|
updatePbc(atom, param);
|
||||||
|
binGhostClusters(param, atom);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user