\doxysection{profile.\+h}
\label{profile_8h_source}\index{include/sphinxbase/profile.h@{include/sphinxbase/profile.h}}
\textbf{ Go to the documentation of this file.}
\begin{DoxyCode}{0}
\DoxyCodeLine{00001\ \textcolor{comment}{/*\ -\/*-\/\ c-\/basic-\/offset:\ 4;\ indent-\/tabs-\/mode:\ nil\ -\/*-\/\ */}}
\DoxyCodeLine{00002\ \textcolor{comment}{/*\ ====================================================================}}
\DoxyCodeLine{00003\ \textcolor{comment}{\ *\ Copyright\ (c)\ 1999-\/2001\ Carnegie\ Mellon\ University.\ \ All\ rights}}
\DoxyCodeLine{00004\ \textcolor{comment}{\ *\ reserved.}}
\DoxyCodeLine{00005\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00006\ \textcolor{comment}{\ *\ Redistribution\ and\ use\ in\ source\ and\ binary\ forms,\ with\ or\ without}}
\DoxyCodeLine{00007\ \textcolor{comment}{\ *\ modification,\ are\ permitted\ provided\ that\ the\ following\ conditions}}
\DoxyCodeLine{00008\ \textcolor{comment}{\ *\ are\ met:}}
\DoxyCodeLine{00009\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00010\ \textcolor{comment}{\ *\ 1.\ Redistributions\ of\ source\ code\ must\ retain\ the\ above\ copyright}}
\DoxyCodeLine{00011\ \textcolor{comment}{\ *\ \ \ \ notice,\ this\ list\ of\ conditions\ and\ the\ following\ disclaimer.\ }}
\DoxyCodeLine{00012\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00013\ \textcolor{comment}{\ *\ 2.\ Redistributions\ in\ binary\ form\ must\ reproduce\ the\ above\ copyright}}
\DoxyCodeLine{00014\ \textcolor{comment}{\ *\ \ \ \ notice,\ this\ list\ of\ conditions\ and\ the\ following\ disclaimer\ in}}
\DoxyCodeLine{00015\ \textcolor{comment}{\ *\ \ \ \ the\ documentation\ and/or\ other\ materials\ provided\ with\ the}}
\DoxyCodeLine{00016\ \textcolor{comment}{\ *\ \ \ \ distribution.}}
\DoxyCodeLine{00017\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00018\ \textcolor{comment}{\ *\ This\ work\ was\ supported\ in\ part\ by\ funding\ from\ the\ Defense\ Advanced\ }}
\DoxyCodeLine{00019\ \textcolor{comment}{\ *\ Research\ Projects\ Agency\ and\ the\ National\ Science\ Foundation\ of\ the\ }}
\DoxyCodeLine{00020\ \textcolor{comment}{\ *\ United\ States\ of\ America,\ and\ the\ CMU\ Sphinx\ Speech\ Consortium.}}
\DoxyCodeLine{00021\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00022\ \textcolor{comment}{\ *\ THIS\ SOFTWARE\ IS\ PROVIDED\ BY\ CARNEGIE\ MELLON\ UNIVERSITY\ \`{}\`{}AS\ IS''\ AND\ }}
\DoxyCodeLine{00023\ \textcolor{comment}{\ *\ ANY\ EXPRESSED\ OR\ IMPLIED\ WARRANTIES,\ INCLUDING,\ BUT\ NOT\ LIMITED\ TO,\ }}
\DoxyCodeLine{00024\ \textcolor{comment}{\ *\ THE\ IMPLIED\ WARRANTIES\ OF\ MERCHANTABILITY\ AND\ FITNESS\ FOR\ A\ PARTICULAR}}
\DoxyCodeLine{00025\ \textcolor{comment}{\ *\ PURPOSE\ ARE\ DISCLAIMED.\ \ IN\ NO\ EVENT\ SHALL\ CARNEGIE\ MELLON\ UNIVERSITY}}
\DoxyCodeLine{00026\ \textcolor{comment}{\ *\ NOR\ ITS\ EMPLOYEES\ BE\ LIABLE\ FOR\ ANY\ DIRECT,\ INDIRECT,\ INCIDENTAL,}}
\DoxyCodeLine{00027\ \textcolor{comment}{\ *\ SPECIAL,\ EXEMPLARY,\ OR\ CONSEQUENTIAL\ DAMAGES\ (INCLUDING,\ BUT\ NOT\ }}
\DoxyCodeLine{00028\ \textcolor{comment}{\ *\ LIMITED\ TO,\ PROCUREMENT\ OF\ SUBSTITUTE\ GOODS\ OR\ SERVICES;\ LOSS\ OF\ USE,\ }}
\DoxyCodeLine{00029\ \textcolor{comment}{\ *\ DATA,\ OR\ PROFITS;\ OR\ BUSINESS\ INTERRUPTION)\ HOWEVER\ CAUSED\ AND\ ON\ ANY\ }}
\DoxyCodeLine{00030\ \textcolor{comment}{\ *\ THEORY\ OF\ LIABILITY,\ WHETHER\ IN\ CONTRACT,\ STRICT\ LIABILITY,\ OR\ TORT\ }}
\DoxyCodeLine{00031\ \textcolor{comment}{\ *\ (INCLUDING\ NEGLIGENCE\ OR\ OTHERWISE)\ ARISING\ IN\ ANY\ WAY\ OUT\ OF\ THE\ USE\ }}
\DoxyCodeLine{00032\ \textcolor{comment}{\ *\ OF\ THIS\ SOFTWARE,\ EVEN\ IF\ ADVISED\ OF\ THE\ POSSIBILITY\ OF\ SUCH\ DAMAGE.}}
\DoxyCodeLine{00033\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00034\ \textcolor{comment}{\ *\ ====================================================================}}
\DoxyCodeLine{00035\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00036\ \textcolor{comment}{\ */}}
\DoxyCodeLine{00037\ \textcolor{comment}{/*}}
\DoxyCodeLine{00038\ \textcolor{comment}{\ *\ profile.h\ -\/-\/\ For\ timing\ and\ event\ counting.}}
\DoxyCodeLine{00039\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00040\ \textcolor{comment}{\ *\ **********************************************}}
\DoxyCodeLine{00041\ \textcolor{comment}{\ *\ CMU\ ARPA\ Speech\ Project}}
\DoxyCodeLine{00042\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00043\ \textcolor{comment}{\ *\ Copyright\ (c)\ 1999\ Carnegie\ Mellon\ University.}}
\DoxyCodeLine{00044\ \textcolor{comment}{\ *\ ALL\ RIGHTS\ RESERVED.}}
\DoxyCodeLine{00045\ \textcolor{comment}{\ *\ **********************************************}}
\DoxyCodeLine{00046\ \textcolor{comment}{\ *\ }}
\DoxyCodeLine{00047\ \textcolor{comment}{\ *\ HISTORY}}
\DoxyCodeLine{00048\ \textcolor{comment}{\ *\ \$Log:\ profile.h,v\ \$}}
\DoxyCodeLine{00049\ \textcolor{comment}{\ *\ Revision\ 1.10\ \ 2005/06/22\ 03:10:59\ \ arthchan2003}}
\DoxyCodeLine{00050\ \textcolor{comment}{\ *\ 1,\ Fixed\ doxygen\ documentation,\ 2,\ Added\ \ keyword.}}
\DoxyCodeLine{00051\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00052\ \textcolor{comment}{\ *\ Revision\ 1.5\ \ 2005/06/15\ 04:21:47\ \ archan}}
\DoxyCodeLine{00053\ \textcolor{comment}{\ *\ 1,\ Fixed\ doxygen-\/documentation,\ 2,\ Add\ \ keyword\ such\ that\ changes\ will\ be\ logged\ into\ a\ file.}}
\DoxyCodeLine{00054\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00055\ \textcolor{comment}{\ *\ Revision\ 1.4\ \ 2005/04/25\ 19:22:48\ \ archan}}
\DoxyCodeLine{00056\ \textcolor{comment}{\ *\ Refactor\ out\ the\ code\ of\ rescoring\ from\ lexical\ tree.\ Potentially\ we\ want\ to\ turn\ off\ the\ rescoring\ if\ we\ need.}}
\DoxyCodeLine{00057\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00058\ \textcolor{comment}{\ *\ Revision\ 1.3\ \ 2005/03/30\ 01:22:48\ \ archan}}
\DoxyCodeLine{00059\ \textcolor{comment}{\ *\ Fixed\ mistakes\ in\ last\ updates.\ Add}}
\DoxyCodeLine{00060\ \textcolor{comment}{\ *}}
\DoxyCodeLine{00061\ \textcolor{comment}{\ *\ }}
\DoxyCodeLine{00062\ \textcolor{comment}{\ *\ 11-\/Mar-\/1999\ \ M\ K\ Ravishankar\ (rkm@cs.cmu.edu)\ at\ Carnegie\ Mellon\ University}}
\DoxyCodeLine{00063\ \textcolor{comment}{\ *\ \ \ \ \ \ \ \ \ \ \ \ \ \ Added\ ptmr\_init().}}
\DoxyCodeLine{00064\ \textcolor{comment}{\ *\ }}
\DoxyCodeLine{00065\ \textcolor{comment}{\ *\ 19-\/Jun-\/97\ \ \ \ M\ K\ Ravishankar\ (rkm@cs.cmu.edu)\ at\ Carnegie\ Mellon\ University}}
\DoxyCodeLine{00066\ \textcolor{comment}{\ *\ \ \ \ \ \ \ \ \ \ \ \ \ \ Created\ from\ earlier\ Sphinx-\/3\ version.}}
\DoxyCodeLine{00067\ \textcolor{comment}{\ */}}
\DoxyCodeLine{00068\ }
\DoxyCodeLine{00069\ }
\DoxyCodeLine{00070\ \textcolor{preprocessor}{\#ifndef\ \_LIBUTIL\_PROFILE\_H\_}}
\DoxyCodeLine{00071\ \textcolor{preprocessor}{\#define\ \_LIBUTIL\_PROFILE\_H\_}}
\DoxyCodeLine{00072\ }
\DoxyCodeLine{00073\ \textcolor{preprocessor}{\#ifdef\ \_\_cplusplus}}
\DoxyCodeLine{00074\ \textcolor{keyword}{extern}\ \textcolor{stringliteral}{"{}C"{}}\ \{}
\DoxyCodeLine{00075\ \textcolor{preprocessor}{\#endif}}
\DoxyCodeLine{00076\ \textcolor{preprocessor}{\#if\ 0}}
\DoxyCodeLine{00077\ \}\ \textcolor{comment}{/*\ Fool\ Emacs\ into\ not\ indenting\ things.\ */}}
\DoxyCodeLine{00078\ \textcolor{preprocessor}{\#endif}}
\DoxyCodeLine{00079\ \ \ }
\DoxyCodeLine{00087\ \textcolor{preprocessor}{\#include\ <stdio.h>}}
\DoxyCodeLine{00088\ }
\DoxyCodeLine{00089\ \textcolor{comment}{/*\ Win32/WinCE\ DLL\ gunk\ */}}
\DoxyCodeLine{00090\ \textcolor{preprocessor}{\#include\ <sphinxbase/sphinxbase\_export.h>}}
\DoxyCodeLine{00091\ \textcolor{preprocessor}{\#include\ <sphinxbase/prim\_type.h>}}
\DoxyCodeLine{00092\ }
\DoxyCodeLine{00093\ }
\DoxyCodeLine{00100\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{}
\DoxyCodeLine{00101\ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{char}\ *name;\ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00104\ \ \ \ \ \ \ \ \ int32\ count;\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00105\ \}\ pctr\_t;}
\DoxyCodeLine{00106\ }
\DoxyCodeLine{00115\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00116\ pctr\_t*\ pctr\_new\ (}
\DoxyCodeLine{00117\ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{char}\ *name\ \ \ }
\DoxyCodeLine{00118\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00119\ }
\DoxyCodeLine{00124\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00125\ \textcolor{keywordtype}{void}\ pctr\_reset\ (pctr\_t\ *ctr\ \ }
\DoxyCodeLine{00126\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00127\ }
\DoxyCodeLine{00131\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00132\ \textcolor{keywordtype}{void}\ pctr\_print(FILE\ *fp,\ \ \ \ \ \ }
\DoxyCodeLine{00133\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ pctr\_t\ *ctr\ \ \ }
\DoxyCodeLine{00134\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00135\ }
\DoxyCodeLine{00139\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00140\ \textcolor{keywordtype}{void}\ pctr\_increment\ (pctr\_t\ *ctr,\ }
\DoxyCodeLine{00141\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ int32\ inc\ \ \ }
\DoxyCodeLine{00142\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00143\ }
\DoxyCodeLine{00147\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00148\ \textcolor{keywordtype}{void}\ pctr\_free(pctr\_t*\ ctr\ }
\DoxyCodeLine{00149\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00150\ }
\DoxyCodeLine{00151\ }
\DoxyCodeLine{00157\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{}
\DoxyCodeLine{00158\ \ \ \ \ \ \ \ \ \textcolor{keyword}{const}\ \textcolor{keywordtype}{char}\ *name;\ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00160\ \ \ \ \ \ \ \ \ float64\ t\_cpu;\ \ \ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00161\ \ \ \ \ \ \ \ \ float64\ t\_elapsed;\ \ \ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00162\ \ \ \ \ \ \ \ \ float64\ t\_tot\_cpu;\ \ \ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00163\ \ \ \ \ \ \ \ \ float64\ t\_tot\_elapsed;\ \ \ \ \ }
\DoxyCodeLine{00164\ \ \ \ \ \ \ \ \ float64\ start\_cpu;\ \ \ \ \ \ \ \ \ \ \ \ \ }
\DoxyCodeLine{00165\ \ \ \ \ \ \ \ \ float64\ start\_elapsed;\ \ \ \ \ }
\DoxyCodeLine{00166\ \}\ ptmr\_t;}
\DoxyCodeLine{00167\ }
\DoxyCodeLine{00168\ }
\DoxyCodeLine{00169\ }
\DoxyCodeLine{00171\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00172\ \textcolor{keywordtype}{void}\ ptmr\_start\ (ptmr\_t\ *tmr\ }
\DoxyCodeLine{00173\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00174\ }
\DoxyCodeLine{00176\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00177\ \textcolor{keywordtype}{void}\ ptmr\_stop\ (ptmr\_t\ *tmr\ \ }
\DoxyCodeLine{00178\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00179\ }
\DoxyCodeLine{00181\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00182\ \textcolor{keywordtype}{void}\ ptmr\_reset\ (ptmr\_t\ *tmr\ \ }
\DoxyCodeLine{00183\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00184\ }
\DoxyCodeLine{00187\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00188\ \textcolor{keywordtype}{void}\ ptmr\_init\ (ptmr\_t\ *tmr\ }
\DoxyCodeLine{00189\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00190\ }
\DoxyCodeLine{00191\ }
\DoxyCodeLine{00196\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00197\ \textcolor{keywordtype}{void}\ ptmr\_reset\_all\ (ptmr\_t\ *tmr\ }
\DoxyCodeLine{00198\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00199\ }
\DoxyCodeLine{00204\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00205\ \textcolor{keywordtype}{void}\ ptmr\_print\_all\ (FILE\ *fp,\ \ \ \ }
\DoxyCodeLine{00206\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ptmr\_t\ *tmr,\ }
\DoxyCodeLine{00207\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ float64\ norm}
\DoxyCodeLine{00208\ \ \ \ \ \ \ \ \ );}
\DoxyCodeLine{00209\ }
\DoxyCodeLine{00210\ }
\DoxyCodeLine{00215\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00216\ int32\ host\_pclk\ (int32\ dummy);}
\DoxyCodeLine{00217\ }
\DoxyCodeLine{00218\ }
\DoxyCodeLine{00219\ \textcolor{comment}{/*}}
\DoxyCodeLine{00220\ \textcolor{comment}{\ *\ Check\ the\ native\ byte-\/ordering\ of\ the\ machine\ by\ writing\ a\ magic}}
\DoxyCodeLine{00221\ \textcolor{comment}{\ *\ number\ to\ a\ temporary\ file\ and\ reading\ it\ back.\ \ *\ Return\ value:}}
\DoxyCodeLine{00222\ \textcolor{comment}{\ *\ 0\ if\ BIG-\/ENDIAN,\ 1\ if\ LITTLE-\/ENDIAN,\ -\/1\ if\ error.\ \ }}
\DoxyCodeLine{00223\ \textcolor{comment}{\ */}}
\DoxyCodeLine{00224\ SPHINXBASE\_EXPORT}
\DoxyCodeLine{00225\ int32\ host\_endian\ (\ \textcolor{keywordtype}{void}\ );}
\DoxyCodeLine{00226\ }
\DoxyCodeLine{00227\ \textcolor{preprocessor}{\#ifdef\ \_\_cplusplus}}
\DoxyCodeLine{00228\ \}}
\DoxyCodeLine{00229\ \textcolor{preprocessor}{\#endif}}
\DoxyCodeLine{00230\ }
\DoxyCodeLine{00231\ \textcolor{preprocessor}{\#endif}}

\end{DoxyCode}
