/usr/share/doc/libhwloc-doc/html/a00091.html is in libhwloc-doc 1.11.2-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>Hardware Locality (hwloc): Linux-specific helpers</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">Hardware Locality (hwloc)
 <span id="projectnumber">1.11.2</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="pages.html"><span>Related Pages</span></a></li>
<li class="current"><a href="modules.html"><span>Modules</span></a></li>
<li><a href="annotated.html"><span>Data Structures</span></a></li>
</ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">Linux-specific helpers</div> </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gaa5a608236c3c0757b0b79818f1d429fb"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="a00091.html#gaa5a608236c3c0757b0b79818f1d429fb">hwloc_linux_parse_cpumap_file</a> (FILE *file, <a class="el" href="a00061.html#ga4bbf39b68b6f568fb92739e7c0ea7801">hwloc_cpuset_t</a> set)</td></tr>
<tr class="separator:gaa5a608236c3c0757b0b79818f1d429fb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga630e699c56b5f3d2e534b475944c216e"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="a00091.html#ga630e699c56b5f3d2e534b475944c216e">hwloc_linux_set_tid_cpubind</a> (<a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> topology, pid_t tid, <a class="el" href="a00061.html#ga1f784433e9b606261f62d1134f6a3b25">hwloc_const_cpuset_t</a> set)</td></tr>
<tr class="separator:ga630e699c56b5f3d2e534b475944c216e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gaddcb985cb56337a4d6693cee72e7bf94"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="a00091.html#gaddcb985cb56337a4d6693cee72e7bf94">hwloc_linux_get_tid_cpubind</a> (<a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> topology, pid_t tid, <a class="el" href="a00061.html#ga4bbf39b68b6f568fb92739e7c0ea7801">hwloc_cpuset_t</a> set)</td></tr>
<tr class="separator:gaddcb985cb56337a4d6693cee72e7bf94"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:gacc7945c2d06c6db1e58f8fd953009134"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="a00091.html#gacc7945c2d06c6db1e58f8fd953009134">hwloc_linux_get_tid_last_cpu_location</a> (<a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> topology, pid_t tid, <a class="el" href="a00084.html#gaa3c2bf4c776d603dcebbb61b0c923d84">hwloc_bitmap_t</a> set)</td></tr>
<tr class="separator:gacc7945c2d06c6db1e58f8fd953009134"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>This includes helpers for manipulating Linux kernel cpumap files, and hwloc equivalents of the Linux sched_setaffinity and sched_getaffinity system calls. </p>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="gaddcb985cb56337a4d6693cee72e7bf94"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int hwloc_linux_get_tid_cpubind </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> </td>
<td class="paramname"><em>topology</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">pid_t </td>
<td class="paramname"><em>tid</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00061.html#ga4bbf39b68b6f568fb92739e7c0ea7801">hwloc_cpuset_t</a> </td>
<td class="paramname"><em>set</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the current binding of thread <code>tid</code>. </p>
<p>The behavior is exactly the same as the Linux sched_getaffinity system call, but uses a hwloc cpuset.</p>
<dl class="section note"><dt>Note</dt><dd>This is equivalent to calling <a class="el" href="a00068.html#gac82de91f788fa82dacf99c6e0d4b7158" title="Get the current physical binding of process pid. ">hwloc_get_proc_cpubind()</a> with <a class="el" href="a00068.html#gga217dc8d373f8958cc93c154ebce1c71caf1b6bbad00d7b1017b918e3719f4d421" title="Bind current thread of current process. ">HWLOC_CPUBIND_THREAD</a> as flags. </dd></dl>
</div>
</div>
<a class="anchor" id="gacc7945c2d06c6db1e58f8fd953009134"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int hwloc_linux_get_tid_last_cpu_location </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> </td>
<td class="paramname"><em>topology</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">pid_t </td>
<td class="paramname"><em>tid</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00084.html#gaa3c2bf4c776d603dcebbb61b0c923d84">hwloc_bitmap_t</a> </td>
<td class="paramname"><em>set</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the last physical CPU where thread <code>tid</code> ran. </p>
<dl class="section note"><dt>Note</dt><dd>This is equivalent to calling <a class="el" href="a00068.html#ga910a05c2d47f68a3155bf176b50fa555" title="Get the last physical CPU where a process ran. ">hwloc_get_proc_last_cpu_location()</a> with <a class="el" href="a00068.html#gga217dc8d373f8958cc93c154ebce1c71caf1b6bbad00d7b1017b918e3719f4d421" title="Bind current thread of current process. ">HWLOC_CPUBIND_THREAD</a> as flags. </dd></dl>
</div>
</div>
<a class="anchor" id="gaa5a608236c3c0757b0b79818f1d429fb"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int hwloc_linux_parse_cpumap_file </td>
<td>(</td>
<td class="paramtype">FILE * </td>
<td class="paramname"><em>file</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00061.html#ga4bbf39b68b6f568fb92739e7c0ea7801">hwloc_cpuset_t</a> </td>
<td class="paramname"><em>set</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Convert a linux kernel cpumap file <code>file</code> into hwloc CPU set. </p>
<p>Might be used when reading CPU set from sysfs attributes such as topology and caches for processors, or local_cpus for devices. </p>
</div>
</div>
<a class="anchor" id="ga630e699c56b5f3d2e534b475944c216e"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int hwloc_linux_set_tid_cpubind </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00064.html#ga9d1e76ee15a7dee158b786c30b6a6e38">hwloc_topology_t</a> </td>
<td class="paramname"><em>topology</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">pid_t </td>
<td class="paramname"><em>tid</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="a00061.html#ga1f784433e9b606261f62d1134f6a3b25">hwloc_const_cpuset_t</a> </td>
<td class="paramname"><em>set</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Bind a thread <code>tid</code> on cpus given in cpuset <code>set</code>. </p>
<p>The behavior is exactly the same as the Linux sched_setaffinity system call, but uses a hwloc cpuset.</p>
<dl class="section note"><dt>Note</dt><dd>This is equivalent to calling <a class="el" href="a00068.html#ga296db8a3c6d49b51fb83d6f3e45c02a6" title="Bind a process pid on cpus given in physical bitmap set. ">hwloc_set_proc_cpubind()</a> with HWLOC_CPUBIND_THREAD as flags. </dd></dl>
</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by  <a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.11
</small></address>
</body>
</html>
|