Commit 4201f34b authored by Philip Carns's avatar Philip Carns

bug fix: mark open and close timestamps in pnetcdf


git-svn-id: https://svn.mcs.anl.gov/repos/darshan/trunk@553 3b7491f3-a168-0410-bf4b-c445ed680a29
parent 4be16c3f
......@@ -77,7 +77,9 @@ int DARSHAN_DECL(ncmpi_create)(MPI_Comm comm, const char *path,
if(file && (file->ncid == -1))
{
file->ncid = *ncidp;
if(CP_F_VALUE(file, CP_F_OPEN_TIMESTAMP) == 0)
CP_F_SET(file, CP_F_OPEN_TIMESTAMP,
PMPI_Wtime());
PMPI_Comm_size(comm, &comm_size);
if(comm_size == 1)
{
......@@ -131,7 +133,9 @@ int DARSHAN_DECL(ncmpi_open)(MPI_Comm comm, const char *path,
if(file && (file->ncid == -1))
{
file->ncid = *ncidp;
if(CP_F_VALUE(file, CP_F_OPEN_TIMESTAMP) == 0)
CP_F_SET(file, CP_F_OPEN_TIMESTAMP,
PMPI_Wtime());
PMPI_Comm_size(comm, &comm_size);
if(comm_size == 1)
{
......@@ -172,6 +176,7 @@ int DARSHAN_DECL(ncmpi_close)(int ncid)
if(file)
{
file->ncid = -1;
CP_F_SET(file, CP_F_CLOSE_TIMESTAMP, PMPI_Wtime());
if(file->ncid_prev == NULL)
{
/* head of ncid hash table list */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment