|
Packit Service |
c5cf8c |
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */
|
|
Packit Service |
c5cf8c |
/*
|
|
Packit Service |
c5cf8c |
*
|
|
Packit Service |
c5cf8c |
* (C) 2001 by Argonne National Laboratory.
|
|
Packit Service |
c5cf8c |
* See COPYRIGHT in top-level directory.
|
|
Packit Service |
c5cf8c |
*/
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
#include "mpiimpl.h"
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
/* -- Begin Profiling Symbol Block for routine MPI_Wtick */
|
|
Packit Service |
c5cf8c |
#if defined(HAVE_PRAGMA_WEAK)
|
|
Packit Service |
c5cf8c |
#pragma weak MPI_Wtick = PMPI_Wtick
|
|
Packit Service |
c5cf8c |
#elif defined(HAVE_PRAGMA_HP_SEC_DEF)
|
|
Packit Service |
c5cf8c |
#pragma _HP_SECONDARY_DEF PMPI_Wtick MPI_Wtick
|
|
Packit Service |
c5cf8c |
#elif defined(HAVE_PRAGMA_CRI_DUP)
|
|
Packit Service |
c5cf8c |
#pragma _CRI duplicate MPI_Wtick as PMPI_Wtick
|
|
Packit Service |
c5cf8c |
#elif defined(HAVE_WEAK_ATTRIBUTE)
|
|
Packit Service |
c5cf8c |
double MPI_Wtick(void) __attribute__ ((weak, alias("PMPI_Wtick")));
|
|
Packit Service |
c5cf8c |
#endif
|
|
Packit Service |
c5cf8c |
/* -- End Profiling Symbol Block */
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
/* Define MPICH_MPI_FROM_PMPI if weak symbols are not supported to build
|
|
Packit Service |
c5cf8c |
the MPI routines */
|
|
Packit Service |
c5cf8c |
#ifndef MPICH_MPI_FROM_PMPI
|
|
Packit Service |
c5cf8c |
#undef MPI_Wtick
|
|
Packit Service |
c5cf8c |
#define MPI_Wtick PMPI_Wtick
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
#endif
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
#undef FUNCNAME
|
|
Packit Service |
c5cf8c |
#define FUNCNAME MPI_Wtick
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
/*@
|
|
Packit Service |
c5cf8c |
MPI_Wtick - Returns the resolution of MPI_Wtime
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
Return value:
|
|
Packit Service |
c5cf8c |
Time in seconds of resolution of MPI_Wtime
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
Notes for Fortran:
|
|
Packit Service |
c5cf8c |
This is a function, declared as 'DOUBLE PRECISION MPI_WTICK()' in Fortran.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.see also: MPI_Wtime, MPI_Comm_get_attr, MPI_Attr_get
|
|
Packit Service |
c5cf8c |
@*/
|
|
Packit Service |
c5cf8c |
double MPI_Wtick(void)
|
|
Packit Service |
c5cf8c |
{
|
|
Packit Service |
c5cf8c |
double tick;
|
|
Packit Service |
c5cf8c |
MPIR_FUNC_TERSE_STATE_DECL(MPID_STATE_MPI_WTICK);
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
MPIR_ERRTEST_INITIALIZED_ORDIE();
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
MPIR_FUNC_TERSE_ENTER(MPID_STATE_MPI_WTICK);
|
|
Packit Service |
c5cf8c |
MPID_Wtick(&tick);
|
|
Packit Service |
c5cf8c |
MPIR_FUNC_TERSE_EXIT(MPID_STATE_MPI_WTICK);
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
return tick;
|
|
Packit Service |
c5cf8c |
}
|