[cig-commits] commit: Fix compiler warnings

Mercurial hg at geodynamics.org
Fri Sep 30 15:00:32 PDT 2011


changeset:   623:8cdf02dfe67c
user:        Walter Landry <wlandry at caltech.edu>
date:        Fri Sep 30 14:57:56 2011 -0700
files:       Swarm/src/ParticleShadowSync.cxx Swarm/src/SwarmDump.cxx Swarm/src/TriGaussParticleLayout.cxx
description:
Fix compiler warnings


diff -r 19119ea2a14c -r 8cdf02dfe67c Swarm/src/ParticleShadowSync.cxx
--- a/Swarm/src/ParticleShadowSync.cxx	Fri Sep 30 14:40:16 2011 -0700
+++ b/Swarm/src/ParticleShadowSync.cxx	Fri Sep 30 14:57:56 2011 -0700
@@ -284,7 +284,6 @@ void _ParticleShadowSync_SendParticleTot
 
 void _ParticleShadowSync_FinishReceiveOfIncomingParticleCounts( ParticleCommHandler* self ) {
 	MPI_Status			status;
-	Processor_Index			proc_I;
 	ShadowInfo*		        cellShadowInfo = CellLayout_GetShadowInfo( self->swarm->cellLayout );
 	ProcNbrInfo*		        procNbrInfo = cellShadowInfo->procNbrInfo;
 	Neighbour_Index		        nbr_I;
@@ -293,8 +292,6 @@ void _ParticleShadowSync_FinishReceiveOf
 	self->swarm->shadowParticleCount = 0;
 	/* TODO: may be worth converting the below into an MPI_Test loop */
 	for ( nbr_I=0; nbr_I < procNbrInfo->procNbrCnt; nbr_I++ ) {
-		proc_I = procNbrInfo->procNbrTbl[nbr_I];
-		
 		MPI_Wait( self->particlesArrivingFromNbrShadowCellCountsHandles[nbr_I], &status );
 
 		self->particlesArrivingFromNbrShadowCellsTotalCounts[nbr_I] = 0;
@@ -355,7 +352,6 @@ void _ParticleShadowSync_FinishReceiveOf
 void _ParticleShadowSync_FinishReceiveOfIncomingParticles( ParticleCommHandler* pCommHandler ) {
 	ParticleShadowSync *self = (ParticleShadowSync*)pCommHandler;
 	MPI_Status			status;
-	Processor_Index			proc_I;
 	ShadowInfo*		        cellShadowInfo = CellLayout_GetShadowInfo( self->swarm->cellLayout );
 	ProcNbrInfo*		        procNbrInfo = cellShadowInfo->procNbrInfo;
 	Neighbour_Index		        nbr_I;
@@ -366,8 +362,6 @@ void _ParticleShadowSync_FinishReceiveOf
 	shadowParticleCounter = 0;
 	/* TODO: may be worth converting the below into an MPI_Test loop */
 	for ( nbr_I=0; nbr_I < procNbrInfo->procNbrCnt; nbr_I++ ) {
-		proc_I = procNbrInfo->procNbrTbl[nbr_I];
-		
 		if( self->particlesArrivingFromNbrShadowCellsTotalCounts[nbr_I] > 0 ){
 			MPI_Wait( self->particlesArrivingFromNbrShadowCellsHandles[nbr_I], &status );
 		}
diff -r 19119ea2a14c -r 8cdf02dfe67c Swarm/src/SwarmDump.cxx
--- a/Swarm/src/SwarmDump.cxx	Fri Sep 30 14:40:16 2011 -0700
+++ b/Swarm/src/SwarmDump.cxx	Fri Sep 30 14:57:56 2011 -0700
@@ -291,7 +291,7 @@ void SwarmDump_DumpToHDF5( SwarmDump* se
    hid_t                   attribData_id, attrib_id, group_id;
    /*herr_t                  status;*/
    hsize_t                 size[2];
-   hsize_t                 cdims[2];
+   // hsize_t                 cdims[2];
    hsize_t                 a_dims;
    int                     attribData;
    hsize_t                 count[2];
@@ -350,8 +350,8 @@ void SwarmDump_DumpToHDF5( SwarmDump* se
             /* set data chunking size.  as we are not opening and closing
                dataset frequently, a large chunk size (the largest!) seems
                appropriate, and gives good compression */
-            cdims[0] = swarm->particleLocalCount;
-            cdims[1] = swarmVar->dofCount;
+            // cdims[0] = swarm->particleLocalCount;
+            // cdims[1] = swarmVar->dofCount;
             
             props  = H5Pcreate( H5P_DATASET_CREATE );
             /* turn on hdf chunking.. as it is required for compression */
diff -r 19119ea2a14c -r 8cdf02dfe67c Swarm/src/TriGaussParticleLayout.cxx
--- a/Swarm/src/TriGaussParticleLayout.cxx	Fri Sep 30 14:40:16 2011 -0700
+++ b/Swarm/src/TriGaussParticleLayout.cxx	Fri Sep 30 14:57:56 2011 -0700
@@ -186,9 +186,7 @@ Particle_InCellIndex _TriGaussParticleLa
 {
 	TriGaussParticleLayout* self = (TriGaussParticleLayout*)triGaussParticleLayout;
 	Particle_InCellIndex count;
-	int dim;	
-	
-	dim = self->dim;
+
 	count = (Particle_InCellIndex)( self->particlesPerCell );
 	
 	return count;



More information about the CIG-COMMITS mailing list