\hypertarget{group__Eina__Cpu__Group}{}\doxysection{Cpu}
\label{group__Eina__Cpu__Group}\index{Cpu@{Cpu}}


Cpu and architecture related helpers.  


\doxysubsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga74e75242132eaabbc1c512488a135926}\label{group__Eina__Cpu__Group_ga74e75242132eaabbc1c512488a135926}} 
\#define {\bfseries M\+IN}(x,  y)~(((x) $>$ (y)) ? (y) \+: (x))
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_gaacc3ee1a7f283f8ef65cea31f4436a95}\label{group__Eina__Cpu__Group_gaacc3ee1a7f283f8ef65cea31f4436a95}} 
\#define {\bfseries M\+AX}(x,  y)~(((x) $>$ (y)) ? (x) \+: (y))
\end{DoxyCompactItemize}
\doxysubsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
typedef enum \+\_\+\+Eina\+\_\+\+Cpu\+\_\+\+Features \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}}
\end{DoxyCompactItemize}
\doxysubsection*{Enumerations}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga8c64fbc734db29a2ac43b25801b5f011}\label{group__Eina__Cpu__Group_ga8c64fbc734db29a2ac43b25801b5f011}} 
enum {\bfseries \+\_\+\+Eina\+\_\+\+Cpu\+\_\+\+Features} \{ \newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+M\+MX} = 0x00000001, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+SE} = 0x00000002, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+S\+E2} = 0x00000004, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+S\+E3} = 0x00000008, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+A\+L\+T\+I\+V\+EC} = 0x00000010, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+V\+IS} = 0x00000020, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+N\+E\+ON} = 0x00000040, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+S\+S\+E3} = 0x00000080, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+S\+E41} = 0x00000100, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+S\+E42} = 0x00000200, 
\newline
{\bfseries E\+I\+N\+A\+\_\+\+C\+P\+U\+\_\+\+S\+VE} = 0x00000400
 \}
\end{DoxyCompactItemize}
\doxysubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}} \mbox{\hyperlink{group__Eina__Cpu__Group_gaf215e6f00fe3332996b890b7a8e8bf51}{eina\+\_\+cpu\+\_\+features\+\_\+get}} (void)
\begin{DoxyCompactList}\small\item\em Cpu features accessor. \end{DoxyCompactList}\item 
\mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} int \mbox{\hyperlink{group__Eina__Cpu__Group_ga34216ac673d316e4e9813d0f68a321f2}{eina\+\_\+cpu\+\_\+count}} (void)
\begin{DoxyCompactList}\small\item\em Gets the current number of processors. \end{DoxyCompactList}\item 
\mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} int \mbox{\hyperlink{group__Eina__Cpu__Group_ga82af2f09a9568dfb4728e958e90d0e9c}{eina\+\_\+cpu\+\_\+page\+\_\+size}} (void)
\begin{DoxyCompactList}\small\item\em Gets the current virtual page size. \end{DoxyCompactList}\item 
static unsigned short \mbox{\hyperlink{group__Eina__Cpu__Group_ga9391dc77f1bac9c5c19548525193077a}{eina\+\_\+swap16}} (unsigned short x)
\begin{DoxyCompactList}\small\item\em Reverses the byte order of a 16-\/bit (destination) register. \end{DoxyCompactList}\item 
static unsigned int \mbox{\hyperlink{group__Eina__Cpu__Group_ga145eac053a5a0bc5a7f99347d3375e1c}{eina\+\_\+swap32}} (unsigned int x)
\begin{DoxyCompactList}\small\item\em Reverses the byte order of a 32-\/bit (destination) register. \end{DoxyCompactList}\item 
static unsigned long long \mbox{\hyperlink{group__Eina__Cpu__Group_ga333e8feb4c7412f32aa0ec817b142948}{eina\+\_\+swap64}} (unsigned long long x)
\begin{DoxyCompactList}\small\item\em Reverses the byte order of a 64-\/bit (destination) register. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_gafb67dfb7eece061a918c7bcb423725ca}\label{group__Eina__Cpu__Group_gafb67dfb7eece061a918c7bcb423725ca}} 
static unsigned short {\bfseries eina\+\_\+htons} (unsigned short host)
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_gac0b5ad3b70c53732cf3d5880dea57d05}\label{group__Eina__Cpu__Group_gac0b5ad3b70c53732cf3d5880dea57d05}} 
static unsigned int {\bfseries eina\+\_\+htonl} (unsigned int host)
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga5f101446487921d98785b87e51663c52}\label{group__Eina__Cpu__Group_ga5f101446487921d98785b87e51663c52}} 
static unsigned long long {\bfseries eina\+\_\+htonll} (unsigned long long host)
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga64494b718f0c2afa4977e4d996e36194}\label{group__Eina__Cpu__Group_ga64494b718f0c2afa4977e4d996e36194}} 
static unsigned short {\bfseries eina\+\_\+ntohs} (unsigned short net)
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga6fdc8310fc939f193eb8ea091788b99b}\label{group__Eina__Cpu__Group_ga6fdc8310fc939f193eb8ea091788b99b}} 
static unsigned int {\bfseries eina\+\_\+ntohl} (unsigned int net)
\item 
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga80249cbc89cdf2edf722f520bed83a43}\label{group__Eina__Cpu__Group_ga80249cbc89cdf2edf722f520bed83a43}} 
static unsigned long long {\bfseries eina\+\_\+ntohll} (unsigned long long net)
\end{DoxyCompactItemize}
\doxysubsection*{Variables}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}} \mbox{\hyperlink{group__Eina__Cpu__Group_gaabf2bf19bc6c111d69a9fd90263df998}{eina\+\_\+cpu\+\_\+features}}
\begin{DoxyCompactList}\small\item\em Global hardware architecture handler. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Cpu and architecture related helpers. 



\doxysubsection{Typedef Documentation}
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}\label{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}} 
\index{Cpu@{Cpu}!Eina\_Cpu\_Features@{Eina\_Cpu\_Features}}
\index{Eina\_Cpu\_Features@{Eina\_Cpu\_Features}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{Eina\_Cpu\_Features}{Eina\_Cpu\_Features}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}}}

Enumerates different hardware architectures. 

\doxysubsection{Function Documentation}
\mbox{\Hypertarget{group__Eina__Cpu__Group_gaf215e6f00fe3332996b890b7a8e8bf51}\label{group__Eina__Cpu__Group_gaf215e6f00fe3332996b890b7a8e8bf51}} 
\index{Cpu@{Cpu}!eina\_cpu\_features\_get@{eina\_cpu\_features\_get}}
\index{eina\_cpu\_features\_get@{eina\_cpu\_features\_get}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_cpu\_features\_get()}{eina\_cpu\_features\_get()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}} eina\+\_\+cpu\+\_\+features\+\_\+get (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Cpu features accessor. 

\begin{DoxyReturn}{Returns}
the current cpu features


\end{DoxyReturn}
\mbox{\Hypertarget{group__Eina__Cpu__Group_ga34216ac673d316e4e9813d0f68a321f2}\label{group__Eina__Cpu__Group_ga34216ac673d316e4e9813d0f68a321f2}} 
\index{Cpu@{Cpu}!eina\_cpu\_count@{eina\_cpu\_count}}
\index{eina\_cpu\_count@{eina\_cpu\_count}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_cpu\_count()}{eina\_cpu\_count()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} int eina\+\_\+cpu\+\_\+count (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Gets the current number of processors. 

\begin{DoxyReturn}{Returns}
The number of processors that are online, that is available when the function is called. 
\end{DoxyReturn}


Referenced by ecore\+\_\+thread\+\_\+max\+\_\+reset(), and ecore\+\_\+thread\+\_\+max\+\_\+set().

\mbox{\Hypertarget{group__Eina__Cpu__Group_ga82af2f09a9568dfb4728e958e90d0e9c}\label{group__Eina__Cpu__Group_ga82af2f09a9568dfb4728e958e90d0e9c}} 
\index{Cpu@{Cpu}!eina\_cpu\_page\_size@{eina\_cpu\_page\_size}}
\index{eina\_cpu\_page\_size@{eina\_cpu\_page\_size}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_cpu\_page\_size()}{eina\_cpu\_page\_size()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} int eina\+\_\+cpu\+\_\+page\+\_\+size (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})}



Gets the current virtual page size. 

\begin{DoxyReturn}{Returns}
The fixed length that represents the smallest unit of data for memory allocation performed by the operating system on behalf of the program, and for transfers between the main memory and any other auxiliary store. 
\end{DoxyReturn}


Referenced by eina\+\_\+mmap\+\_\+safety\+\_\+enabled\+\_\+set().

\mbox{\Hypertarget{group__Eina__Cpu__Group_ga9391dc77f1bac9c5c19548525193077a}\label{group__Eina__Cpu__Group_ga9391dc77f1bac9c5c19548525193077a}} 
\index{Cpu@{Cpu}!eina\_swap16@{eina\_swap16}}
\index{eina\_swap16@{eina\_swap16}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_swap16()}{eina\_swap16()}}
{\footnotesize\ttfamily static unsigned short eina\+\_\+swap16 (\begin{DoxyParamCaption}\item[{unsigned short}]{x }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Reverses the byte order of a 16-\/bit (destination) register. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em x} & The binary word to swap \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A byte order swapped 16-\/bit integer. ~\newline

\end{DoxyReturn}
On big endian systems, the number is converted to little endian byte order. On little endian systems, the number is converted to big endian byte order. \mbox{\Hypertarget{group__Eina__Cpu__Group_ga145eac053a5a0bc5a7f99347d3375e1c}\label{group__Eina__Cpu__Group_ga145eac053a5a0bc5a7f99347d3375e1c}} 
\index{Cpu@{Cpu}!eina\_swap32@{eina\_swap32}}
\index{eina\_swap32@{eina\_swap32}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_swap32()}{eina\_swap32()}}
{\footnotesize\ttfamily static unsigned int eina\+\_\+swap32 (\begin{DoxyParamCaption}\item[{unsigned int}]{x }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Reverses the byte order of a 32-\/bit (destination) register. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em x} & The binary word to swap \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A byte order swapped 32-\/bit integer. ~\newline

\end{DoxyReturn}
On big endian systems, the number is converted to little endian byte order. On little endian systems, the number is converted to big endian byte order. \mbox{\Hypertarget{group__Eina__Cpu__Group_ga333e8feb4c7412f32aa0ec817b142948}\label{group__Eina__Cpu__Group_ga333e8feb4c7412f32aa0ec817b142948}} 
\index{Cpu@{Cpu}!eina\_swap64@{eina\_swap64}}
\index{eina\_swap64@{eina\_swap64}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_swap64()}{eina\_swap64()}}
{\footnotesize\ttfamily static unsigned long long eina\+\_\+swap64 (\begin{DoxyParamCaption}\item[{unsigned long long}]{x }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Reverses the byte order of a 64-\/bit (destination) register. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em x} & The binary word to swap \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
A byte order swapped 64-\/bit integer.
\end{DoxyReturn}
On big endian systems, the number is converted to little endian byte order. On little endian systems, the number is converted to big endian byte order. 

\doxysubsection{Variable Documentation}
\mbox{\Hypertarget{group__Eina__Cpu__Group_gaabf2bf19bc6c111d69a9fd90263df998}\label{group__Eina__Cpu__Group_gaabf2bf19bc6c111d69a9fd90263df998}} 
\index{Cpu@{Cpu}!eina\_cpu\_features@{eina\_cpu\_features}}
\index{eina\_cpu\_features@{eina\_cpu\_features}!Cpu@{Cpu}}
\doxysubsubsection{\texorpdfstring{eina\_cpu\_features}{eina\_cpu\_features}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Elua_ga3db3556eec8ef18cb8ddb43816974ac8}{E\+A\+PI}} \mbox{\hyperlink{group__Eina__Cpu__Group_ga5b1c582b9cbe7cf337aedb4f80f78a7f}{Eina\+\_\+\+Cpu\+\_\+\+Features}} eina\+\_\+cpu\+\_\+features}



Global hardware architecture handler. 

\begin{DoxyReturn}{Returns}
the current cpu features 
\end{DoxyReturn}
