File: a00393.html

package info (click to toggle)
hwloc 2.4.1%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 22,032 kB
  • sloc: ansic: 58,129; xml: 12,064; sh: 6,822; makefile: 2,200; javascript: 1,623; perl: 380; cpp: 93; php: 8; sed: 4
file content (97 lines) | stat: -rw-r--r-- 6,890 bytes parent folder | download | duplicates (2)
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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://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.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Hardware Locality (hwloc): Topology Attributes: Distances, Memory Attributes and CPU Kinds</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)
   &#160;<span id="projectnumber">2.4.1</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','Search');
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div class="PageDoc"><div class="header">
  <div class="headertitle">
<div class="title">Topology Attributes: Distances, Memory Attributes and CPU Kinds </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p> 
<div class="section">
</p>
<p>Besides the hierarchy of objects and individual object attributes (see <a class="el" href="a00392.html">Object attributes</a>), hwloc may also expose finer information about the hardware organization.</p>
<p> 
</div><div class="section" id="topoattrs_distances">
 </p>
<h1><a class="anchor" id="topoattrs_distances"></a>
Distances</h1>
<p>A machine with 4 CPUs may have identical links between every pairs of CPUs, or those CPUs could also only be connected through a ring. In the ring case, accessing the memory of nearby CPUs is slower than local memory, but it is also faster than accessing the memory of CPU on the opposite side of the ring. These deep details cannot be exposed in the hwloc hierarchy, that is why hwloc also exposes distances.</p>
<p>Distances are matrices of values between sets of objects, usually latencies or bandwidths. By default, hwloc tries to get a matrix of relative latencies between NUMA nodes when exposed by the hardware.</p>
<p>In the aforementioned ring case, the matrix could report 10 for latency between a NUMA node and itself, 20 for nearby nodes, and 30 for nodes that are opposites on the ring. Those are theoretical values exposed by hardware vendors (in the System Locality Distance Information Table (SLIT) in the ACPI) rather than physical latencies. They are mostly meant for comparing node relative distances.</p>
<p>Distances structures currently created by hwloc are: </p><dl>
<dt>NUMALatency (Linux, Solaris, FreeBSD) </dt>
<dd>This is the matrix of theoretical latencies described above.  </dd>
</dl>
<p>Users may also specify their own matrices between any set of objects, even if these objects are of different types (e.g. bandwidths between GPUs and CPUs).</p>
<p>The entire API is located in <a class="el" href="a00137_source.html">hwloc/distances.h</a>. See also <a class="el" href="a00214.html">Retrieve distances between objects</a>, as well as <a class="el" href="a00215.html">Helpers for consulting distance matrices</a> and <a class="el" href="a00216.html">Add or remove distances between objects</a>.</p>
<p> 
</div><div class="section" id="topoattrs_memattrs">
 </p>
<h1><a class="anchor" id="topoattrs_memattrs"></a>
Memory Attributes</h1>
<p>Machines with heterogeneous memory, for instance high-bandwidth memory (HBM), normal memory (DDR), and/or high-capacity slow memory (such as non-volatile memory DIMMs, NVDIMMs) require applications to allocate buffers in the appropriate target memory depending on performance and capacity needs. Those target nodes may be exposed in the hwloc hierarchy as different memory children but there is a need for performance information to select the appropriate one.</p>
<p>hwloc memory attributes are designed to expose memory information such as latency, bandwidth, etc. Users may also specify their own attributes and values.</p>
<p>The memory attributes API is located in <a class="el" href="a00140_source.html">hwloc/memattrs.h</a>, see <a class="el" href="a00217.html">Comparing memory node attributes for finding where to allocate on</a> and <a class="el" href="a00218.html">Managing memory attributes</a> for details.</p>
<p> 
</div><div class="section" id="topoattrs_cpukinds">
 </p>
<h1><a class="anchor" id="topoattrs_cpukinds"></a>
CPU Kinds</h1>
<p>Hybrid CPUs may contain different kinds of cores. The CPU kinds API in <a class="el" href="a00143_source.html">hwloc/cpukinds.h</a> provides a way to list the sets of PUs in each kind and get some optional information about their hardware characteristics and efficiency.</p>
<p>If the operating system provides efficiency information (e.g. Windows 10), it is used to rank hwloc CPU kinds by efficiency. Otherwise, hwloc implements several heuristics based on frequencies and core types (see HWLOC_CPUKINDS_RANKING in <a class="el" href="a00388.html">Environment Variables</a>).</p>
<p>Attributes include: </p><dl>
<dt>FrequencyMaxMHz (Linux) </dt>
<dd>The maximal operating frequency of the core, as reported by <code>cpufreq</code> drivers on Linux.  </dd>
<dt>FrequencyBaseMHz (Linux) </dt>
<dd>The base operating frequency of the core, as reported by some <code>cpufreq</code> drivers on Linux (e.g. <code>intel_pstate</code>).  </dd>
<dt>CoreType (x86, Linux) </dt>
<dd>A string describing the kind of core, currently <code>IntelAtom</code> or <code>IntelCore</code>, as reported by the x86 CPUID instruction and future Linux kernels on some Intel processors.  </dd>
<dt>LinuxCPUType (Linux) </dt>
<dd>The Linux-specific CPU type found in sysfs, such as <code>intel_atom_0</code>, as reported by future Linux kernels on some Intel processors.  </dd>
</dl>
<p>See <a class="el" href="a00219.html">Kinds of CPU cores</a> for details. </p>
</div></div><!-- contents -->
</div><!-- PageDoc -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
</small></address>
</body>
</html>