Skip to content

Commit

Permalink
changed tests to PIOc_free_iosystem()
Browse files Browse the repository at this point in the history
  • Loading branch information
edhartnett committed Jun 4, 2019
1 parent f3840b4 commit 9132d9f
Show file tree
Hide file tree
Showing 40 changed files with 49 additions and 49 deletions.
2 changes: 1 addition & 1 deletion tests/cunit/test_async_3proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ int main(int argc, char **argv)
/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
{
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
}
} /* endif comp_task */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_4proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ int main(int argc, char **argv)

/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
} /* endif comp_task */

Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_manyproc.c
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ int main(int argc, char **argv)

/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
} /* endif comp_task */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_mpi.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* This program tests some MPI functionality that is used in PIO. This
* runs on three processors, and does the same MPI commands that are
* done when async mode is used, with 1 IO task, and two computation
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_multi2.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ int main(int argc, char **argv)

/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
} /* endif comp_task */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_multicomp.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ int main(int argc, char **argv)

/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
} /* endif comp_task */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_perf.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

/* Free the computation conomponent communicator. */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_async_simple.c
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ int main(int argc, char **argv)

/* Finalize the IO system. Only call this from the computation tasks. */
for (int c = 0; c < COMPONENT_COUNT; c++)
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
} /* endif comp_task */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_common.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* Common test code for PIO C tests.
*
* Ed Hartnett
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray.c
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next rearranger */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_1d.c
Original file line number Diff line number Diff line change
Expand Up @@ -865,7 +865,7 @@ int main(int argc, char **argv)
}

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next rearranger */

Expand Down
4 changes: 2 additions & 2 deletions tests/cunit/test_darray_2sync.c
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ int run_async_tests(MPI_Comm test_comm, int my_rank, int num_iotypes, int *iotyp
ERR(ret);

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

/* Free the computation conomponent communicator. */
Expand Down Expand Up @@ -548,7 +548,7 @@ int run_noasync_tests(MPI_Comm test_comm, int my_rank, int num_iotypes, int *iot
ERR(ret);

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

return PIO_NOERR;
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_3d.c
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* next rearranger */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_async.c
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_free_iosystem(iosysid)))
if ((ret = PIOc_free_iosystem (iosysid)))
return ret;

/* Free the computation conomponent communicator. */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_async_many.c
Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

/* Free the computation conomponent communicator. */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_async_simple.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

/* Free the computation conomponent communicator. */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_fill.c
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ int main(int argc, char **argv)
} /* next fill value test case */

/* Finalize PIO iosysid. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next rearranger */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_frame.c
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next rearranger */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_multi.c
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next rearranger */
} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_multivar.c
Original file line number Diff line number Diff line change
Expand Up @@ -587,7 +587,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
}

Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_multivar2.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_darray_multivar3.c
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ int main(int argc, char **argv)
ERR(ret);

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_decomp_frame.c
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ int main(int argc, char **argv)
} /* next rearranger */

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* endif my_rank < TARGET_NTASKS */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_decomp_uneven.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ int main(int argc, char **argv)
}

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* next rearranger */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_decomps.c
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ int main(int argc, char **argv)
ERR(ret);

/* Finalize PIO systems. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
ERR(ret);
} /* next io test */
} /* next rearranger */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_intercomm2.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ int main(int argc, char **argv)
} /* next netcdf flavor */

/* Finalize the IO system. Only call this from the computation tasks. */
if ((ret = PIOc_finalize(iosysid[my_comp_idx])))
if ((ret = PIOc_free_iosystem(iosysid[my_comp_idx])))
ERR(ret);
}
} /* my_rank < TARGET_NTASKS */
Expand Down
6 changes: 3 additions & 3 deletions tests/cunit/test_iosystem2.c
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ int main(int argc, char **argv)
ERR(ret);

/* This should fail. */
if (PIOc_finalize(iosysid + TEST_VAL_42) != PIO_EBADID)
if (PIOc_free_iosystem(iosysid + TEST_VAL_42) != PIO_EBADID)
ERR(ERR_WRONG);

/* Initialize another PIO system. */
Expand Down Expand Up @@ -201,11 +201,11 @@ int main(int argc, char **argv)
MPIERR(ret);

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
ERR(ret);

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);
} /* my_rank < TARGET_NTASKS */

Expand Down
4 changes: 2 additions & 2 deletions tests/cunit/test_iosystem2_simple.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,12 +221,12 @@ int main(int argc, char **argv)
MPIERR(ret);

/* Finalize PIO odd/even intracomm. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
ERR(ret);


/* Finalize PIO world intracomm. */
if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);
}/* my_rank < TARGET_NTASKS */

Expand Down
4 changes: 2 additions & 2 deletions tests/cunit/test_iosystem2_simple2.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,11 @@ int main(int argc, char **argv)
MPIERR(ret);

/* Finalize PIO odd/even intracomm. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
ERR(ret);

/* Finalize PIO world intracomm. */
if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);
} /* my_rank < TARGET_NTASKS */

Expand Down
6 changes: 3 additions & 3 deletions tests/cunit/test_iosystem3.c
Original file line number Diff line number Diff line change
Expand Up @@ -317,14 +317,14 @@ int main(int argc, char **argv)

/* Finalize PIO systems. */
if (even_comm != MPI_COMM_NULL)
if ((ret = PIOc_finalize(even_iosysid)))
if ((ret = PIOc_free_iosystem(even_iosysid)))
ERR(ret);
if (overlap_comm != MPI_COMM_NULL)
{
if ((ret = PIOc_finalize(overlap_iosysid)))
if ((ret = PIOc_free_iosystem(overlap_iosysid)))
ERR(ret);
}
if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);

/* Free MPI resources used by test. */
Expand Down
4 changes: 2 additions & 2 deletions tests/cunit/test_iosystem3_simple.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ int main(int argc, char **argv)

/* Finalize PIO system. */
if (overlap_comm != MPI_COMM_NULL)
if ((ret = PIOc_finalize(overlap_iosysid)))
if ((ret = PIOc_free_iosystem(overlap_iosysid)))
ERR(ret);

if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);

/* Free MPI resources used by test. */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_iosystem3_simple2.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ int main(int argc, char **argv)
} /* next iotype */

/* Finalize PIO systems. */
if ((ret = PIOc_finalize(iosysid_world)))
if ((ret = PIOc_free_iosystem(iosysid_world)))
ERR(ret);
} /* my_rank < TARGET_NTASKS */

Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_perf2.c
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* next rearranger */
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_pioc.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* Tests for PIO Functions.
*
* @author Ed Hartnett
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_pioc_fill.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* More tests for PIO data reading and writing routines.
*
* Ed Hartnett
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_pioc_putget.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* Tests for PIO data reading and writing routines.
*
* @author Ed Hartnett
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_pioc_unlim.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
* Tests for PIO Functions. In this test we use a simple 3D variable,
* with an unlimited dimension. The data will have two timesteps, and
* 4x4 elements each timestep.
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_rearr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1578,7 +1578,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;
} /* next numio */
} /* next rearranger */
Expand Down
4 changes: 2 additions & 2 deletions tests/cunit/test_shared.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ int test_async2(int my_rank, int num_flavors, int *flavor, MPI_Comm test_comm,
return ret;

/* Finalize the IO system. Only call this from the computation tasks. */
if ((ret = PIOc_finalize(iosysid[c])))
if ((ret = PIOc_free_iosystem(iosysid[c])))
ERR(ret);
if ((mpierr = MPI_Comm_free(&comp_comm[c])))
MPIERR(mpierr);
Expand Down Expand Up @@ -118,7 +118,7 @@ int test_no_async2(int my_rank, int num_flavors, int *flavor, MPI_Comm test_comm
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

return PIO_NOERR;
Expand Down
2 changes: 1 addition & 1 deletion tests/cunit/test_spmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,7 @@ int main(int argc, char **argv)
return ret;

/* Finalize PIO system. */
if ((ret = PIOc_finalize(iosysid)))
if ((ret = PIOc_free_iosystem(iosysid)))
return ret;

} /* endif my_rank < TARGET_NTASKS */
Expand Down

0 comments on commit 9132d9f

Please sign in to comment.