\hypertarget{group__hwlocality__configuration}{\section{Configure Topology Detection}
\label{group__hwlocality__configuration}\index{Configure Topology Detection@{Configure Topology Detection}}
}


These functions can optionally be called between \hyperlink{group__hwlocality__creation_ga5c2d6f476af87005c7bd0811d4548b9f}{hwloc\+\_\+topology\+\_\+init()} and \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to configure how the detection should be performed, e.\+g.  


\subsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct \hyperlink{structhwloc__topology__discovery__support}{hwloc\+\_\+topology\+\_\+discovery\+\_\+support}
\begin{DoxyCompactList}\small\item\em Flags describing actual discovery support for this topology. \end{DoxyCompactList}\item 
struct \hyperlink{structhwloc__topology__cpubind__support}{hwloc\+\_\+topology\+\_\+cpubind\+\_\+support}
\begin{DoxyCompactList}\small\item\em Flags describing actual P\+U binding support for this topology. \end{DoxyCompactList}\item 
struct \hyperlink{structhwloc__topology__membind__support}{hwloc\+\_\+topology\+\_\+membind\+\_\+support}
\begin{DoxyCompactList}\small\item\em Flags describing actual memory binding support for this topology. \end{DoxyCompactList}\item 
struct \hyperlink{structhwloc__topology__support}{hwloc\+\_\+topology\+\_\+support}
\begin{DoxyCompactList}\small\item\em Set of flags describing actual support for this topology. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Enumerations}
\begin{DoxyCompactItemize}
\item 
enum \hyperlink{group__hwlocality__configuration_gada025d3ec20b4b420f8038d23d6e7bde}{hwloc\+\_\+topology\+\_\+flags\+\_\+e} \{ \\*
\hyperlink{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea129b4fea1300be22bbaf0bb0958994c8}{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M}, 
\hyperlink{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea6ecb6abc6a0bb75e81564f8bca85783b}{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M}, 
{\bfseries H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+O\+\_\+\+D\+E\+V\+I\+C\+E\+S} = (1$<$$<$2), 
{\bfseries H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+O\+\_\+\+B\+R\+I\+D\+G\+E\+S} = (1$<$$<$3), 
\\*
{\bfseries H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+I\+O} = (1$<$$<$4)
 \}
\begin{DoxyCompactList}\small\item\em Flags to be set onto a topology context before load. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_gaf2071c8621fddc53649c245d87835b47}{hwloc\+\_\+topology\+\_\+ignore\+\_\+type} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} topology, \hyperlink{group__hwlocality__types_gacd37bb612667dc437d66bfb175a8dc55}{hwloc\+\_\+obj\+\_\+type\+\_\+t} type)
\begin{DoxyCompactList}\small\item\em Ignore an object type. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_ga6ddd4213d95bd1c30555b294a60efa6b}{hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} topology, \hyperlink{group__hwlocality__types_gacd37bb612667dc437d66bfb175a8dc55}{hwloc\+\_\+obj\+\_\+type\+\_\+t} type)
\begin{DoxyCompactList}\small\item\em Ignore an object type if it does not bring any structure. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_gaec6fb00050f50cd41007f1ae580d2106}{hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} topology)
\begin{DoxyCompactList}\small\item\em Ignore all objects that do not bring any structure. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_ga6d11e53db143ac39c32cdb3912b71f99}{hwloc\+\_\+topology\+\_\+set\+\_\+flags} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} topology, unsigned long flags)
\begin{DoxyCompactList}\small\item\em Set O\+R'ed flags to non-\/yet-\/loaded topology. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_ga2f6bfb6958d8b508ea1d7d5bb266432c}{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict fsroot\+\_\+path)
\begin{DoxyCompactList}\small\item\em Change the file-\/system root path when building the topology from sysfs/procfs. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_gae1100de0162b3c6a9db750ac14629c05}{hwloc\+\_\+topology\+\_\+set\+\_\+pid} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, hwloc\+\_\+pid\+\_\+t pid)
\begin{DoxyCompactList}\small\item\em Change which pid the topology is viewed from. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_ga2fcb52181b586c20f001b7a999550324}{hwloc\+\_\+topology\+\_\+set\+\_\+synthetic} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict description)
\begin{DoxyCompactList}\small\item\em Enable synthetic topology. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}{hwloc\+\_\+topology\+\_\+set\+\_\+xml} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict xmlpath)
\begin{DoxyCompactList}\small\item\em Enable X\+M\+L-\/file based topology. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_gae7e4bade144652a2b48f5eaf0309b4ec}{hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict buffer, int size)
\begin{DoxyCompactList}\small\item\em Enable X\+M\+L based topology using a memory buffer (instead of a file, as with \hyperlink{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}{hwloc\+\_\+topology\+\_\+set\+\_\+xml()}). \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{group__hwlocality__configuration_gabda6afa67a495cd652f064ad51d3fe47}{hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology, \hyperlink{group__hwlocality__types_gacd37bb612667dc437d66bfb175a8dc55}{hwloc\+\_\+obj\+\_\+type\+\_\+t} type, unsigned nbobjs, unsigned $\ast$os\+\_\+index, float $\ast$distances)
\begin{DoxyCompactList}\small\item\em Provide a distance matrix. \end{DoxyCompactList}\item 
H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C const struct \\*
\hyperlink{structhwloc__topology__support}{hwloc\+\_\+topology\+\_\+support} $\ast$ \hyperlink{group__hwlocality__configuration_ga3dccb46b5c1bb5a4c78995b3e183e64f}{hwloc\+\_\+topology\+\_\+get\+\_\+support} (\hyperlink{group__hwlocality__topology_ga9d1e76ee15a7dee158b786c30b6a6e38}{hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict topology)
\begin{DoxyCompactList}\small\item\em Retrieve the topology support. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
These functions can optionally be called between \hyperlink{group__hwlocality__creation_ga5c2d6f476af87005c7bd0811d4548b9f}{hwloc\+\_\+topology\+\_\+init()} and \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to configure how the detection should be performed, e.\+g. 

to ignore some objects types, define a synthetic topology, etc.

If none of them is called, the default is to detect all the objects of the machine that the caller is allowed to access.

This default behavior may also be modified through environment variables if the application did not modify it already. Setting H\+W\+L\+O\+C\+\_\+\+X\+M\+L\+F\+I\+L\+E in the environment enforces the discovery from a X\+M\+L file as if \hyperlink{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}{hwloc\+\_\+topology\+\_\+set\+\_\+xml()} had been called. H\+W\+L\+O\+C\+\_\+\+F\+S\+R\+O\+O\+T switches to reading the topology from the specified Linux filesystem root as if \hyperlink{group__hwlocality__configuration_ga2f6bfb6958d8b508ea1d7d5bb266432c}{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot()} had been called. Finally, H\+W\+L\+O\+C\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M enforces the return value of \hyperlink{group__hwlocality__information_ga0d109e33fc7990f62f665d336e5e5111}{hwloc\+\_\+topology\+\_\+is\+\_\+thissystem()}. 

\subsection{Enumeration Type Documentation}
\hypertarget{group__hwlocality__configuration_gada025d3ec20b4b420f8038d23d6e7bde}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+flags\+\_\+e@{hwloc\+\_\+topology\+\_\+flags\+\_\+e}}
\index{hwloc\+\_\+topology\+\_\+flags\+\_\+e@{hwloc\+\_\+topology\+\_\+flags\+\_\+e}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+flags\+\_\+e}]{\setlength{\rightskip}{0pt plus 5cm}enum {\bf hwloc\+\_\+topology\+\_\+flags\+\_\+e}}}\label{group__hwlocality__configuration_gada025d3ec20b4b420f8038d23d6e7bde}


Flags to be set onto a topology context before load. 

Flags should be given to \hyperlink{group__hwlocality__configuration_ga6d11e53db143ac39c32cdb3912b71f99}{hwloc\+\_\+topology\+\_\+set\+\_\+flags()}. \begin{Desc}
\item[Enumerator]\par
\begin{description}
\index{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M@{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M}!Configure Topology Detection@{Configure Topology Detection}}\index{Configure Topology Detection@{Configure Topology Detection}!H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M@{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M}}\item[{\em 
\hypertarget{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea129b4fea1300be22bbaf0bb0958994c8}{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+W\+H\+O\+L\+E\+\_\+\+S\+Y\+S\+T\+E\+M}\label{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea129b4fea1300be22bbaf0bb0958994c8}
}]Detect the whole system, ignore reservations and offline settings. Gather all resources, even if some were disabled by the administrator. For instance, ignore Linux Cpusets and gather all processors and memory nodes, and ignore the fact that some resources may be offline. \index{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M@{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M}!Configure Topology Detection@{Configure Topology Detection}}\index{Configure Topology Detection@{Configure Topology Detection}!H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M@{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M}}\item[{\em 
\hypertarget{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea6ecb6abc6a0bb75e81564f8bca85783b}{H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M}\label{group__hwlocality__configuration_ggada025d3ec20b4b420f8038d23d6e7bdea6ecb6abc6a0bb75e81564f8bca85783b}
}]Assume that the selected backend provides the topology for the system on which we are running. This forces hwloc\+\_\+topology\+\_\+is\+\_\+thissystem to return 1, i.\+e. makes hwloc assume that the selected backend provides the topology for the system on which we are running, even if it is not the O\+S-\/specific backend but the X\+M\+L backend for instance. This means making the binding functions actually call the O\+S-\/specific system calls and really do binding, while the X\+M\+L backend would otherwise provide empty hooks just returning success.

Setting the environment variable H\+W\+L\+O\+C\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M may also result in the same behavior.

This can be used for efficiency reasons to first detect the topology once, save it to an X\+M\+L file, and quickly reload it later through the X\+M\+L backend, but still having binding functions actually do bind. \end{description}
\end{Desc}


\subsection{Function Documentation}
\hypertarget{group__hwlocality__configuration_ga3dccb46b5c1bb5a4c78995b3e183e64f}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+get\+\_\+support@{hwloc\+\_\+topology\+\_\+get\+\_\+support}}
\index{hwloc\+\_\+topology\+\_\+get\+\_\+support@{hwloc\+\_\+topology\+\_\+get\+\_\+support}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+get\+\_\+support}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C const struct {\bf hwloc\+\_\+topology\+\_\+support}$\ast$ hwloc\+\_\+topology\+\_\+get\+\_\+support (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga3dccb46b5c1bb5a4c78995b3e183e64f}


Retrieve the topology support. 



Referenced by ompi\+\_\+mpi\+\_\+init().

\hypertarget{group__hwlocality__configuration_gaec6fb00050f50cd41007f1ae580d2106}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure@{hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure}}
\index{hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure@{hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+ignore\+\_\+all\+\_\+keep\+\_\+structure (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t}}]{topology}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_gaec6fb00050f50cd41007f1ae580d2106}


Ignore all objects that do not bring any structure. 

Ignore all objects that do not bring any structure\+: Each ignored object should have a single children or be the only child of its parent. I/\+O objects may not be ignored, topology flags should be used to configure their discovery instead. \hypertarget{group__hwlocality__configuration_gaf2071c8621fddc53649c245d87835b47}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+ignore\+\_\+type@{hwloc\+\_\+topology\+\_\+ignore\+\_\+type}}
\index{hwloc\+\_\+topology\+\_\+ignore\+\_\+type@{hwloc\+\_\+topology\+\_\+ignore\+\_\+type}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+ignore\+\_\+type}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+ignore\+\_\+type (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t}}]{topology, }
\item[{{\bf hwloc\+\_\+obj\+\_\+type\+\_\+t}}]{type}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_gaf2071c8621fddc53649c245d87835b47}


Ignore an object type. 

Ignore all objects from the given type. The bottom-\/level type H\+W\+L\+O\+C\+\_\+\+O\+B\+J\+\_\+\+P\+U may not be ignored. The top-\/level object of the hierarchy will never be ignored, even if this function succeeds. I/\+O objects may not be ignored, topology flags should be used to configure their discovery instead. \hypertarget{group__hwlocality__configuration_ga6ddd4213d95bd1c30555b294a60efa6b}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure@{hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure}}
\index{hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure@{hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+ignore\+\_\+type\+\_\+keep\+\_\+structure (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t}}]{topology, }
\item[{{\bf hwloc\+\_\+obj\+\_\+type\+\_\+t}}]{type}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga6ddd4213d95bd1c30555b294a60efa6b}


Ignore an object type if it does not bring any structure. 

Ignore all objects from the given type as long as they do not bring any structure\+: Each ignored object should have a single children or be the only child of its parent. The bottom-\/level type H\+W\+L\+O\+C\+\_\+\+O\+B\+J\+\_\+\+P\+U may not be ignored. I/\+O objects may not be ignored, topology flags should be used to configure their discovery instead. \hypertarget{group__hwlocality__configuration_gabda6afa67a495cd652f064ad51d3fe47}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix@{hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix@{hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+distance\+\_\+matrix (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{{\bf hwloc\+\_\+obj\+\_\+type\+\_\+t}}]{type, }
\item[{unsigned}]{nbobjs, }
\item[{unsigned $\ast$}]{os\+\_\+index, }
\item[{float $\ast$}]{distances}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_gabda6afa67a495cd652f064ad51d3fe47}


Provide a distance matrix. 

Provide the matrix of distances between a set of objects of the given type. The set may or may not contain all the existing objects of this type. The objects are specified by their O\+S/physical index in the {\ttfamily os\+\_\+index} array. The {\ttfamily distances} matrix follows the same order. The distance from object i to object j in the i$\ast$nbobjs+j.

A single latency matrix may be defined for each type. If another distance matrix already exists for the given type, either because the user specified it or because the O\+S offers it, it will be replaced by the given one. If {\ttfamily nbobjs} is {\ttfamily 0}, {\ttfamily os\+\_\+index} is {\ttfamily N\+U\+L\+L} and {\ttfamily distances} is {\ttfamily N\+U\+L\+L}, the existing distance matrix for the given type is removed. \hypertarget{group__hwlocality__configuration_ga6d11e53db143ac39c32cdb3912b71f99}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+flags@{hwloc\+\_\+topology\+\_\+set\+\_\+flags}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+flags@{hwloc\+\_\+topology\+\_\+set\+\_\+flags}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+flags}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+flags (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t}}]{topology, }
\item[{unsigned long}]{flags}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga6d11e53db143ac39c32cdb3912b71f99}


Set O\+R'ed flags to non-\/yet-\/loaded topology. 

Set a O\+R'ed set of \hyperlink{group__hwlocality__configuration_gada025d3ec20b4b420f8038d23d6e7bde}{hwloc\+\_\+topology\+\_\+flags\+\_\+e} onto a topology that was not yet loaded. \hypertarget{group__hwlocality__configuration_ga2f6bfb6958d8b508ea1d7d5bb266432c}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+fsroot@{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot@{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+fsroot}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+fsroot (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict}]{fsroot\+\_\+path}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga2f6bfb6958d8b508ea1d7d5bb266432c}


Change the file-\/system root path when building the topology from sysfs/procfs. 

On Linux system, use sysfs and procfs files as if they were mounted on the given {\ttfamily fsroot\+\_\+path} instead of the main file-\/system root. Setting the environment variable H\+W\+L\+O\+C\+\_\+\+F\+S\+R\+O\+O\+T may also result in this behavior. Not using the main file-\/system root causes \hyperlink{group__hwlocality__information_ga0d109e33fc7990f62f665d336e5e5111}{hwloc\+\_\+topology\+\_\+is\+\_\+thissystem()} to return 0.

Note that this function does not actually load topology information; it just tells hwloc where to load it from. You'll still need to invoke \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to actually load the topology information.

\begin{DoxyNote}{Note}
For convenience, this backend provides empty binding hooks which just return success. To have hwloc still actually call O\+S-\/specific hooks, the H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M has to be set to assert that the loaded file is really the underlying system. 
\end{DoxyNote}
\hypertarget{group__hwlocality__configuration_gae1100de0162b3c6a9db750ac14629c05}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+pid@{hwloc\+\_\+topology\+\_\+set\+\_\+pid}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+pid@{hwloc\+\_\+topology\+\_\+set\+\_\+pid}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+pid}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+pid (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{hwloc\+\_\+pid\+\_\+t}]{pid}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_gae1100de0162b3c6a9db750ac14629c05}


Change which pid the topology is viewed from. 

On some systems, processes may have different views of the machine, for instance the set of allowed C\+P\+Us. By default, hwloc exposes the view from the current process. Calling \hyperlink{group__hwlocality__configuration_gae1100de0162b3c6a9db750ac14629c05}{hwloc\+\_\+topology\+\_\+set\+\_\+pid()} permits to make it expose the topology of the machine from the point of view of another process.

\begin{DoxyNote}{Note}
{\ttfamily hwloc\+\_\+pid\+\_\+t} is {\ttfamily pid\+\_\+t} on Unix platforms, and {\ttfamily H\+A\+N\+D\+L\+E} on native Windows platforms.

-\/1 is returned and errno is set to E\+N\+O\+S\+Y\+S on platforms that do not support this feature. 
\end{DoxyNote}
\hypertarget{group__hwlocality__configuration_ga2fcb52181b586c20f001b7a999550324}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+synthetic@{hwloc\+\_\+topology\+\_\+set\+\_\+synthetic}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+synthetic@{hwloc\+\_\+topology\+\_\+set\+\_\+synthetic}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+synthetic}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+synthetic (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict}]{description}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga2fcb52181b586c20f001b7a999550324}


Enable synthetic topology. 

Gather topology information from the given {\ttfamily description}, a space-\/separated string of numbers describing the arity of each level. Each number may be prefixed with a type and a colon to enforce the type of a level. If only some level types are enforced, hwloc will try to choose the other types according to usual topologies, but it may fail and you may have to specify more level types manually.

If {\ttfamily description} was properly parsed and describes a valid topology configuration, this function returns 0. Otherwise -\/1 is returned and errno is set to E\+I\+N\+V\+A\+L.

Note that this function does not actually load topology information; it just tells hwloc where to load it from. You'll still need to invoke \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to actually load the topology information.

\begin{DoxyNote}{Note}
For convenience, this backend provides empty binding hooks which just return success. 
\end{DoxyNote}
\hypertarget{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+xml@{hwloc\+\_\+topology\+\_\+set\+\_\+xml}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+xml@{hwloc\+\_\+topology\+\_\+set\+\_\+xml}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+xml}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+xml (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict}]{xmlpath}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}


Enable X\+M\+L-\/file based topology. 

Gather topology information from the X\+M\+L file given at {\ttfamily xmlpath}. Setting the environment variable H\+W\+L\+O\+C\+\_\+\+X\+M\+L\+F\+I\+L\+E may also result in this behavior. This file may have been generated earlier with lstopo file.\+xml.

Note that this function does not actually load topology information; it just tells hwloc where to load it from. You'll still need to invoke \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to actually load the topology information.

\begin{DoxyNote}{Note}
For convenience, this backend provides empty binding hooks which just return success. To have hwloc still actually call O\+S-\/specific hooks, the H\+W\+L\+O\+C\+\_\+\+T\+O\+P\+O\+L\+O\+G\+Y\+\_\+\+F\+L\+A\+G\+\_\+\+I\+S\+\_\+\+T\+H\+I\+S\+S\+Y\+S\+T\+E\+M has to be set to assert that the loaded file is really the underlying system. 
\end{DoxyNote}
\hypertarget{group__hwlocality__configuration_gae7e4bade144652a2b48f5eaf0309b4ec}{\index{Configure Topology Detection@{Configure Topology Detection}!hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer@{hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer}}
\index{hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer@{hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer}!Configure Topology Detection@{Configure Topology Detection}}
\subsubsection[{hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer}]{\setlength{\rightskip}{0pt plus 5cm}H\+W\+L\+O\+C\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int hwloc\+\_\+topology\+\_\+set\+\_\+xmlbuffer (
\begin{DoxyParamCaption}
\item[{{\bf hwloc\+\_\+topology\+\_\+t} \+\_\+\+\_\+hwloc\+\_\+restrict}]{topology, }
\item[{const char $\ast$\+\_\+\+\_\+hwloc\+\_\+restrict}]{buffer, }
\item[{int}]{size}
\end{DoxyParamCaption}
)}}\label{group__hwlocality__configuration_gae7e4bade144652a2b48f5eaf0309b4ec}


Enable X\+M\+L based topology using a memory buffer (instead of a file, as with \hyperlink{group__hwlocality__configuration_ga93efcc8a962afe1ed23393700682173f}{hwloc\+\_\+topology\+\_\+set\+\_\+xml()}). 

Gather topology information from the X\+M\+L memory buffer given at {\ttfamily buffer} and of length {\ttfamily size}. This buffer may have been filled earlier with \hyperlink{group__hwlocality__tinker_ga739330e9402425315e44e5012631fb91}{hwloc\+\_\+topology\+\_\+export\+\_\+xmlbuffer()}.

Note that this function does not actually load topology information; it just tells hwloc where to load it from. You'll still need to invoke \hyperlink{group__hwlocality__creation_ga91e2e6427b95fb7339c99dbbef996e71}{hwloc\+\_\+topology\+\_\+load()} to actually load the topology information. 