git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@6335 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp 2011-06-08 18:16:56 +00:00
parent 1c3275156a
commit 3249c38780
5 changed files with 20 additions and 12 deletions

View File

@ -26,10 +26,6 @@ class Comm : protected Pointers {
int myloc[3]; // which proc I am in each dim
int procneigh[3][2]; // my 6 neighboring procs
int ghost_velocity; // 1 if ghost atoms have velocity, 0 if not
int maxforward_fix; // comm sizes called from Fix,Pair
int maxreverse_fix;
int maxforward_pair;
int maxreverse_pair;
double cutghost[3]; // cutoffs used for acquiring ghost atoms
double cutghostuser; // user-specified ghost cutoff
int ***grid2proc; // which proc owns i,j,k loc in 3d grid
@ -45,12 +41,14 @@ class Comm : protected Pointers {
virtual void exchange(); // move atoms to new procs
virtual void borders(); // setup list of atoms to communicate
virtual void forward_comm_pair(class Pair *); // forward comm from a Pair
virtual void reverse_comm_pair(class Pair *); // reverse comm from a Pair
virtual void forward_comm_fix(class Fix *); // forward comm from a Fix
virtual void reverse_comm_fix(class Fix *); // reverse comm from a Fix
virtual void forward_comm_compute(class Compute *); // forward comm from a Compute
virtual void reverse_comm_compute(class Compute *); // reverse comm from a Compute
virtual void forward_comm_pair(class Pair *); // forward comm from a Pair
virtual void reverse_comm_pair(class Pair *); // reverse comm from a Pair
virtual void forward_comm_fix(class Fix *); // forward comm from a Fix
virtual void reverse_comm_fix(class Fix *); // reverse comm from a Fix
virtual void forward_comm_compute(class Compute *); // forward from a Compute
virtual void reverse_comm_compute(class Compute *); // reverse from a Compute
virtual void forward_comm_dump(class Dump *); // forward comm from a Dump
virtual void reverse_comm_dump(class Dump *); // reverse comm from a Dump
virtual void set(int, char **); // set communication style
virtual bigint memory_usage();

View File

@ -63,6 +63,8 @@ Dump::Dump(LAMMPS *lmp, int narg, char **arg) : Pointers(lmp)
filename = new char[n];
strcpy(filename,arg[4]);
comm_forward = comm_reverse = 0;
first_flag = 0;
flush_flag = 1;
format = NULL;

View File

@ -28,6 +28,9 @@ class Dump : protected Pointers {
int first_flag; // 0 if no initial dump, 1 if yes initial dump
int clearstep; // 1 if dump invokes computes, 0 if not
int comm_forward; // size of forward communication (0 if none)
int comm_reverse; // size of reverse communication (0 if none)
// static variable across all Dump objects
static Dump *dumpptr; // holds a ptr to Dump currently being used
@ -36,6 +39,12 @@ class Dump : protected Pointers {
virtual ~Dump();
void init();
virtual void write();
virtual int pack_comm(int, int *, double *, int, int *) {return 0;}
virtual void unpack_comm(int, int, double *) {}
virtual int pack_reverse_comm(int, int, double *) {return 0;}
virtual void unpack_reverse_comm(int, int *, double *) {}
void modify_params(int, char **);
virtual bigint memory_usage();

View File

@ -47,6 +47,7 @@ class DumpCustom : public Dump {
int maxlocal; // size of atom selection and variable arrays
int *choose; // local indices of selected atoms
double *dchoose; // value for each atom to threshhold against
int *clist; // compressed list of indices of selected atoms
int nfield; // # of keywords listed by user
int ioptional; // index of start of optional args

View File

@ -103,8 +103,6 @@ void Force::init()
{
qqrd2e = qqr2e/dielectric;
comm->maxforward_pair = comm->maxreverse_pair = 0;
if (kspace) kspace->init(); // kspace must come before pair
if (pair) pair->init(); // so g_ewald is defined
if (bond) bond->init();