\hypertarget{namespacemom__cpu__clock}{}\section{mom\+\_\+cpu\+\_\+clock Module Reference}
\label{namespacemom__cpu__clock}\index{mom\_cpu\_clock@{mom\_cpu\_clock}}


\subsection{Detailed Description}
Wraps the M\+PP cpu clock functions. \subsection*{Functions/\+Subroutines}
\begin{DoxyCompactItemize}
\item 
integer function, public \mbox{\hyperlink{namespacemom__cpu__clock_a7fda795074ed5ec5b00a26e7531c14f3}{cpu\+\_\+clock\+\_\+id}} (name, synchro\+\_\+flag, grain)
\begin{DoxyCompactList}\small\item\em cpu\+\_\+clock\+\_\+id returns the integer handle for a named C\+PU clock. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Function/\+Subroutine Documentation}
\mbox{\Hypertarget{namespacemom__cpu__clock_a7fda795074ed5ec5b00a26e7531c14f3}\label{namespacemom__cpu__clock_a7fda795074ed5ec5b00a26e7531c14f3}} 
\index{mom\_cpu\_clock@{mom\_cpu\_clock}!cpu\_clock\_id@{cpu\_clock\_id}}
\index{cpu\_clock\_id@{cpu\_clock\_id}!mom\_cpu\_clock@{mom\_cpu\_clock}}
\subsubsection{\texorpdfstring{cpu\_clock\_id()}{cpu\_clock\_id()}}
{\footnotesize\ttfamily integer function, public mom\+\_\+cpu\+\_\+clock\+::cpu\+\_\+clock\+\_\+id (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{integer, intent(in), optional}]{synchro\+\_\+flag,  }\item[{integer, intent(in), optional}]{grain }\end{DoxyParamCaption})}



cpu\+\_\+clock\+\_\+id returns the integer handle for a named C\+PU clock. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em name} & The unique name of the C\+PU clock \\
\hline
\mbox{\texttt{ in}}  & {\em synchro\+\_\+flag} & An integer flag that controls whether the P\+Es are synchronized before the cpu clocks start counting. Synchronization occurs before the start of a clock if this is odd, while additional (expensive) statistics can set for other values. If absent, the default is taken from the settings for F\+MS. \\
\hline
\mbox{\texttt{ in}}  & {\em grain} & The timing granularity for this clock, usually set to the values of C\+L\+O\+C\+K\+\_\+\+C\+O\+M\+P\+O\+N\+E\+NT, C\+L\+O\+C\+K\+\_\+\+R\+O\+U\+T\+I\+NE, C\+L\+O\+C\+K\+\_\+\+L\+O\+OP, etc. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The integer C\+PU clock handle. 
\end{DoxyReturn}


Definition at line 23 of file M\+O\+M\+\_\+cpu\+\_\+clock.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{23   \textcolor{keywordtype}{character(len=*)},  \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{  !< The unique name of the CPU clock}}
\DoxyCodeLine{24   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)}, \textcolor{keywordtype}{optional} :: synchro\_flag\textcolor{comment}{ !< An integer flag that controls whether the PEs}}
\DoxyCodeLine{25 \textcolor{comment}{                                       !! are synchronized before the cpu clocks start counting.}}
\DoxyCodeLine{26 \textcolor{comment}{                                       !! Synchronization occurs before the start of a clock if this}}
\DoxyCodeLine{27 \textcolor{comment}{                                       !! is odd, while additional (expensive) statistics can set}}
\DoxyCodeLine{28 \textcolor{comment}{                                       !! for other values. If absent, the default is taken from the}}
\DoxyCodeLine{29 \textcolor{comment}{                                       !! settings for FMS.}}
\DoxyCodeLine{30   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)}, \textcolor{keywordtype}{optional} :: grain\textcolor{comment}{ !< The timing granularity for this clock, usually set to}}
\DoxyCodeLine{31 \textcolor{comment}{                                       !! the values of CLOCK\_COMPONENT, CLOCK\_ROUTINE, CLOCK\_LOOP, etc.}}
\DoxyCodeLine{32   \textcolor{keywordtype}{integer}                       :: cpu\_clock\_id\textcolor{comment}{ !< The integer CPU clock handle.}}
\DoxyCodeLine{33 }
\DoxyCodeLine{34   \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(synchro\_flag)) \textcolor{keywordflow}{then}}
\DoxyCodeLine{35     cpu\_clock\_id = mpp\_clock\_id(name, flags=synchro\_flag, grain=grain)}
\DoxyCodeLine{36   \textcolor{keywordflow}{else}}
\DoxyCodeLine{37     cpu\_clock\_id = mpp\_clock\_id(name, flags=clock\_flag\_default, grain=grain)}
\DoxyCodeLine{38 \textcolor{keywordflow}{  endif}}
\DoxyCodeLine{39 }

\end{DoxyCode}
