/*************************************************************************
- * *
+ * *
* N A S P A R A L L E L B E N C H M A R K S 3.3 *
* *
* D T *
* *
- *************************************************************************
+ *************************************************************************
* *
* This benchmark is part of the NAS Parallel Benchmark 3.3 suite. *
* *
* E-mail: npb@nas.nasa.gov *
* Fax: (650) 604-3957 *
* *
- *************************************************************************
+ *************************************************************************
* *
* Author: M. Frumkin * *
* *
numPrevLayerNodes=numLayerNodes;
}
source=newNode((char*)"Source");
- AttachNode(dg,source);
+ AttachNode(dg,source);
for(i=0;i<numPrevLayerNodes;i++){
nd=dg->node[firstLayerNode+i];
ar=newArc(source,nd);
numPrevLayerNodes=numLayerNodes;
}
sink=newNode((char*)"Sink");
- AttachNode(dg,sink);
+ AttachNode(dg,sink);
for(i=0;i<numPrevLayerNodes;i++){
nd=dg->node[firstLayerNode+i];
ar=newArc(nd,sink);
int i=0,j=0,k=0;
double rms0=0.0,rms1=0.0,rmsm1=0.0;
double weight=((double) (w+1))/(w+2);
-
+
w+=1;
if(timer_on){
timer_clear(w);
dg=buildSH(class);
}
- if(timer_on != 0 && dg && dg->numNodes+1>timers_tot){
+ if(timer_on != 0 && dg->numNodes+1>timers_tot){
timer_on=0;
if(my_rank==0)
fprintf(stderr,"Not enough timers. Node timeing is off. \n");
}
- if(dg && dg->numNodes>comm_size){
+ if(dg->numNodes>comm_size){
if(my_rank==0){
fprintf(stderr,"** The number of MPI processes should not be less than \n");
fprintf(stderr,"** the number of nodes in the graph\n");
MPI_Finalize();
exit(0);
}
- for(i=0;i<dg->numNodes;i++){
+ for(i=0; i<dg->numNodes; i++){
dg->node[i]->address=i;
}
if( my_rank == 0 ){