mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-01-18 08:51:45 -08:00
319 lines
No EOL
20 KiB
HTML
319 lines
No EOL
20 KiB
HTML
|
|
|
|
<!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/html; charset=utf-8" />
|
|
|
|
<title>Memory Management Glossary: O — Memory Pool System 1.111.0 documentation</title>
|
|
|
|
<link rel="stylesheet" href="../_static/mps.css" type="text/css" />
|
|
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
|
|
|
|
<script type="text/javascript">
|
|
var DOCUMENTATION_OPTIONS = {
|
|
URL_ROOT: '../',
|
|
VERSION: '1.111.0',
|
|
COLLAPSE_INDEX: false,
|
|
FILE_SUFFIX: '.html',
|
|
HAS_SOURCE: true
|
|
};
|
|
</script>
|
|
<script type="text/javascript" src="../_static/jquery.js"></script>
|
|
<script type="text/javascript" src="../_static/underscore.js"></script>
|
|
<script type="text/javascript" src="../_static/doctools.js"></script>
|
|
<link rel="copyright" title="Copyright" href="../copyright.html" />
|
|
<link rel="top" title="Memory Pool System 1.111.0 documentation" href="../index.html" />
|
|
<link rel="up" title="Memory Management Glossary" href="index.html" />
|
|
<link rel="next" title="Memory Management Glossary: P" href="p.html" />
|
|
<link rel="prev" title="Memory Management Glossary: N" href="n.html" />
|
|
</head>
|
|
<body>
|
|
<div class="related">
|
|
<h3>Navigation</h3>
|
|
<ul>
|
|
<li class="right" style="margin-right: 10px">
|
|
<a href="../genindex.html" title="General Index"
|
|
accesskey="I">index</a></li>
|
|
<li class="right" >
|
|
<a href="p.html" title="Memory Management Glossary: P"
|
|
accesskey="N">next</a> |</li>
|
|
<li class="right" >
|
|
<a href="n.html" title="Memory Management Glossary: N"
|
|
accesskey="P">previous</a> |</li>
|
|
<li><a href="../index.html">Memory Pool System 1.111.0 documentation</a> »</li>
|
|
<li><a href="index.html" accesskey="U">Memory Management Glossary</a> »</li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="document">
|
|
<div class="documentwrapper">
|
|
<div class="bodywrapper">
|
|
<div class="body">
|
|
|
|
<div class="section" id="memory-management-glossary-o">
|
|
<span id="glossary-o"></span><h1>Memory Management Glossary: O<a class="headerlink" href="#memory-management-glossary-o" title="Permalink to this headline">¶</a></h1>
|
|
<p class="glossary-alphabet"><a class="reference internal" href="a.html#glossary-a"><em>A</em></a>
|
|
| <a class="reference internal" href="b.html#glossary-b"><em>B</em></a>
|
|
| <a class="reference internal" href="c.html#glossary-c"><em>C</em></a>
|
|
| <a class="reference internal" href="d.html#glossary-d"><em>D</em></a>
|
|
| <a class="reference internal" href="e.html#glossary-e"><em>E</em></a>
|
|
| <a class="reference internal" href="f.html#glossary-f"><em>F</em></a>
|
|
| <a class="reference internal" href="g.html#glossary-g"><em>G</em></a>
|
|
| <a class="reference internal" href="h.html#glossary-h"><em>H</em></a>
|
|
| <a class="reference internal" href="i.html#glossary-i"><em>I</em></a>
|
|
| J
|
|
| <a class="reference internal" href="k.html#glossary-k"><em>K</em></a>
|
|
| <a class="reference internal" href="l.html#glossary-l"><em>L</em></a>
|
|
| <a class="reference internal" href="m.html#glossary-m"><em>M</em></a>
|
|
| <a class="reference internal" href="n.html#glossary-n"><em>N</em></a>
|
|
| <a class="reference internal" href="#glossary-o"><em>O</em></a>
|
|
| <a class="reference internal" href="p.html#glossary-p"><em>P</em></a>
|
|
| <a class="reference internal" href="q.html#glossary-q"><em>Q</em></a>
|
|
| <a class="reference internal" href="r.html#glossary-r"><em>R</em></a>
|
|
| <a class="reference internal" href="s.html#glossary-s"><em>S</em></a>
|
|
| <a class="reference internal" href="t.html#glossary-t"><em>T</em></a>
|
|
| <a class="reference internal" href="u.html#glossary-u"><em>U</em></a>
|
|
| <a class="reference internal" href="v.html#glossary-v"><em>V</em></a>
|
|
| <a class="reference internal" href="w.html#glossary-w"><em>W</em></a>
|
|
| X
|
|
| Y
|
|
| <a class="reference internal" href="z.html#glossary-z"><em>Z</em></a></p>
|
|
<dl class="glossary docutils">
|
|
<dt id="term-object">object</dt>
|
|
<dd><div class="admonition-also-known-as first admonition">
|
|
<p class="first admonition-title">Also known as</p>
|
|
<p class="last"><em>cell</em>.</p>
|
|
</div>
|
|
<p>In <a class="reference internal" href="m.html#term-memory-management"><em class="xref std std-term">memory management</em></a>, we use the term <em>object</em> or
|
|
<em>cell</em> to mean a contiguous <a class="reference internal" href="b.html#term-block"><em class="xref std std-term">block</em></a> of <a class="reference internal" href="m.html#term-memory-2"><em class="xref std std-term">memory<sup>(2)</sup></em></a> forming a single logical structure.</p>
|
|
<p>Objects are the units of <a class="reference internal" href="a.html#term-allocate"><em class="xref std std-term">allocation</em></a>,
|
|
<a class="reference internal" href="f.html#term-free-1"><em class="xref std std-term">deallocation</em></a>, etc. No connection to an
|
|
object-oriented system is implied.</p>
|
|
<div class="admonition-in-the-mps last admonition">
|
|
<p class="first admonition-title">In the MPS</p>
|
|
<p class="last">The MPS documentation generally reserves the term <em>object</em>
|
|
for <a class="reference internal" href="f.html#term-formatted-object"><em class="xref std std-term">formatted objects</em></a>. For
|
|
units of allocation in general, it uses the term
|
|
<a class="reference internal" href="b.html#term-block"><em class="xref std std-term">block</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-object-format">object format</dt>
|
|
<dd><div class="admonition-in-the-mps first last admonition">
|
|
<p class="first admonition-title">In the MPS</p>
|
|
<p class="last">A data structure provided by the <a class="reference internal" href="c.html#term-client-program"><em class="xref std std-term">client program</em></a>
|
|
which describes the format of <a class="reference internal" href="f.html#term-formatted-object"><em class="xref std std-term">objects</em></a> allocated in a <a class="reference internal" href="p.html#term-pool"><em class="xref std std-term">pool</em></a>. The MPS uses the
|
|
<a class="reference internal" href="f.html#term-format-method"><em class="xref std std-term">format methods</em></a> to find
|
|
<a class="reference internal" href="r.html#term-reference"><em class="xref std std-term">references</em></a> in an object, replace an
|
|
object with <a class="reference internal" href="p.html#term-padding"><em class="xref std std-term">padding</em></a>, replace an object with a
|
|
<a class="reference internal" href="f.html#term-forwarding-marker"><em class="xref std std-term">forwarding marker</em></a>, and other essential
|
|
<a class="reference internal" href="g.html#term-garbage-collection"><em class="xref std std-term">garbage collection</em></a> tasks. See <a class="reference internal" href="../topic/format.html#topic-format"><em>Object formats</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-object-pointer">object pointer</dt>
|
|
<dd><p class="first">In the <a class="reference internal" href="../mmref/lang.html#term-c"><em class="xref std std-term">C</em></a> programming language, a <a class="reference internal" href="p.html#term-pointer"><em class="xref std std-term">pointer</em></a> to an
|
|
<a class="reference internal" href="#term-object"><em class="xref std std-term">object</em></a>, as distinct from a <a class="reference internal" href="f.html#term-function-pointer"><em class="xref std std-term">function pointer</em></a>.
|
|
The C programming language guarantees that you can cast any
|
|
object pointer to <tt class="docutils literal"><span class="pre">void</span> <span class="pre">*</span></tt> and back without losing
|
|
information.</p>
|
|
<div class="admonition-opposite-term last admonition">
|
|
<p class="first admonition-title">Opposite term</p>
|
|
<p class="last"><a class="reference internal" href="f.html#term-function-pointer"><em class="xref std std-term">function pointer</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-off-white">off-white</dt>
|
|
<dd><div class="admonition-also-known-as first admonition">
|
|
<p class="first admonition-title">Also known as</p>
|
|
<p class="last"><em>ecru</em>.</p>
|
|
</div>
|
|
<p>In a <a class="reference internal" href="t.html#term-treadmill"><em class="xref std std-term">treadmill</em></a> <a class="reference internal" href="g.html#term-garbage-collector"><em class="xref std std-term">garbage collector</em></a>, the
|
|
<a class="reference internal" href="c.html#term-color"><em class="xref std std-term">color</em></a> off-white is used to describe <a class="reference internal" href="#term-object"><em class="xref std std-term">objects</em></a>
|
|
which are <a class="reference internal" href="f.html#term-free-3"><em class="xref std std-term">free<sup>(3)</sup></em></a>. <a class="reference internal" href="../mmref/bib.html#baker92c"><em>Baker (1992c)</em></a>
|
|
used the term <em>ecru</em>.</p>
|
|
<div class="admonition-opposite-term admonition">
|
|
<p class="first admonition-title">Opposite terms</p>
|
|
<p class="last"><a class="reference internal" href="w.html#term-white"><em class="xref std std-term">white</em></a>, <a class="reference internal" href="g.html#term-gray"><em class="xref std std-term">gray</em></a>, <a class="reference internal" href="b.html#term-black"><em class="xref std std-term">black</em></a>.</p>
|
|
</div>
|
|
<div class="admonition-see-also last admonition seealso">
|
|
<p class="first admonition-title">See also</p>
|
|
<p class="last"><a class="reference internal" href="t.html#term-treadmill"><em class="xref std std-term">treadmill</em></a>, <a class="reference internal" href="c.html#term-color"><em class="xref std std-term">color</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-old-space"><span id="term-oldspace"></span>old space<br />oldspace</dt>
|
|
<dd><div class="admonition-see first last admonition">
|
|
<p class="first admonition-title">See</p>
|
|
<p class="last"><a class="reference internal" href="f.html#term-fromspace"><em class="xref std std-term">fromspace</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-one-bit-reference-count">one-bit reference count</dt>
|
|
<dd><p class="first">The one-bit <a class="reference internal" href="r.html#term-reference-counting"><em class="xref std std-term">reference count</em></a> is a
|
|
heuristic mechanism that lets a program test, at low cost,
|
|
whether an <a class="reference internal" href="#term-object"><em class="xref std std-term">object</em></a> is <a class="reference internal" href="d.html#term-dead"><em class="xref std std-term">dead</em></a>.</p>
|
|
<p>The one-bit reference count is a special case of the
|
|
<a class="reference internal" href="l.html#term-limited-field-reference-count"><em class="xref std std-term">limited-field reference count</em></a>. A single bit in an
|
|
object, called the MRB (Multiple Reference Bit), is cleared
|
|
when the object is <a class="reference internal" href="a.html#term-allocate"><em class="xref std std-term">allocated</em></a>. Whenever another
|
|
<a class="reference internal" href="r.html#term-reference"><em class="xref std std-term">reference</em></a> to the object is created, the bit is set.
|
|
Thus, MRB=0 indicates that there is exactly one reference to
|
|
the object, and MRB=1 indicates that there may be more than
|
|
one reference to the object.</p>
|
|
<p>The MRB can be stored in the reference rather than in the
|
|
object; doing so reduces the number of memory accesses due to
|
|
MRB checking and setting. When a reference is copied, the
|
|
copy’s MRB is set. If the MRB in the old reference is 0, it
|
|
also needs to be set. Setting the MRB in the old reference
|
|
requires that the program knows the location the old reference
|
|
came from, and that it can prove that location has not since
|
|
been overwritten with other data.</p>
|
|
<p>The one-bit reference count is used by a compiler to augment
|
|
an object lifetime analysis. When compile-time analysis
|
|
predicts that a particular object may be dead (typically
|
|
because the variable that references the object is dead), the
|
|
compiler can generate code that will check the object’s MRB at
|
|
run-time. If the MRB is 0, then the object is dead.</p>
|
|
<p>Using a one-bit reference count does have a cost: the MRB uses
|
|
space that could sometimes be put to other use, and the MRB
|
|
must be set every time the number of references to the object
|
|
increases. The one-bit reference count is cheaper than other
|
|
kinds of reference counting, however, since the space cost is
|
|
only one bit and the reference count is not adjusted when
|
|
references are destroyed.</p>
|
|
<div class="admonition-historical-note admonition">
|
|
<p class="first admonition-title">Historical note</p>
|
|
<p class="last">The one-bit reference count was suggested by
|
|
<a class="reference internal" href="../mmref/bib.html#fw77"><em>Friedman & Wise (1977)</em></a>. Storing the MRB in
|
|
the reference was suggested by <a class="reference internal" href="../mmref/bib.html#scn84"><em>Stoye, Clarke, and
|
|
Norman (1984)</em></a>.</p>
|
|
</div>
|
|
<div class="admonition-related-publication last admonition">
|
|
<p class="first admonition-title">Related publication</p>
|
|
<p class="last"><a class="reference internal" href="../mmref/bib.html#jones12"><em>Jones et al. (2012)</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-opaque-type">opaque type</dt>
|
|
<dd><div class="admonition-in-the-mps first admonition">
|
|
<p class="first admonition-title">In the MPS</p>
|
|
<p class="last">In the MPS interface, an <em>opaque type</em> is a pointer to an
|
|
incomplete structure type. The client programs must not
|
|
rely on the details of its implementation. For example,
|
|
the type <a class="reference internal" href="../topic/arena.html#mps_arena_t" title="mps_arena_t"><tt class="xref c c-type docutils literal"><span class="pre">mps_arena_t</span></tt></a> is an alias for <tt class="docutils literal"><span class="pre">struct</span>
|
|
<span class="pre">mps_arena_s</span> <span class="pre">*</span></tt>, but the implementation of <tt class="docutils literal"><span class="pre">struct</span>
|
|
<span class="pre">mps_arena_s</span></tt> is not public. See <a class="reference internal" href="../topic/interface.html#topic-interface"><em>Interface conventions</em></a>.</p>
|
|
</div>
|
|
<div class="admonition-opposite-term last admonition">
|
|
<p class="first admonition-title">Opposite terms</p>
|
|
<p class="last"><a class="reference internal" href="d.html#term-derived-type"><em class="xref std std-term">derived type</em></a>, <a class="reference internal" href="t.html#term-transparent-type"><em class="xref std std-term">transparent type</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-out-parameter">out parameter</dt>
|
|
<dd><p class="first">A function parameter that points to a location for the caller
|
|
to receive data from the function.</p>
|
|
<div class="admonition-opposite-term admonition">
|
|
<p class="first admonition-title">Opposite term</p>
|
|
<p class="last"><a class="reference internal" href="i.html#term-in-parameter"><em class="xref std std-term">in parameter</em></a>.</p>
|
|
</div>
|
|
<div class="admonition-in-the-mps last admonition">
|
|
<p class="first admonition-title">In the MPS</p>
|
|
<p class="last">Out parameters are given names ending with <tt class="docutils literal"><span class="pre">_o</span></tt>. See
|
|
<a class="reference internal" href="../topic/interface.html#topic-interface"><em>Interface conventions</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-out-of-band-header">out-of-band header</dt>
|
|
<dd><p class="first">In some <a class="reference internal" href="m.html#term-memory-manager"><em class="xref std std-term">memory managers</em></a>, each <a class="reference internal" href="a.html#term-allocate"><em class="xref std std-term">allocated</em></a>
|
|
<a class="reference internal" href="b.html#term-block"><em class="xref std std-term">block</em></a> has additional information (such as the size of
|
|
the block or a <a class="reference internal" href="t.html#term-tag"><em class="xref std std-term">tag</em></a>) stored in a separate block; this
|
|
is called <em>an out-of-band header</em>.</p>
|
|
<div class="admonition-opposite-term last admonition">
|
|
<p class="first admonition-title">Opposite term</p>
|
|
<p class="last"><a class="reference internal" href="i.html#term-in-band-header"><em class="xref std std-term">in-band header</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
<dt id="term-overcommit">overcommit</dt>
|
|
<dd><p class="first">In some circumstances, although a range of <a class="reference internal" href="v.html#term-virtual-address"><em class="xref std std-term">virtual
|
|
addresses</em></a> has been <a class="reference internal" href="m.html#term-mapped"><em class="xref std std-term">mapped</em></a> as far as the user program
|
|
is concerned, the <a class="reference internal" href="p.html#term-physical-storage"><em class="xref std std-term">physical storage</em></a> might not be
|
|
allocated until it is accessed. This is called
|
|
<em>overcommitting</em>.</p>
|
|
<p>Overcommitting shares <a class="reference internal" href="s.html#term-swap-space"><em class="xref std std-term">swap space</em></a> resources more
|
|
flexibly, especially when crude <a class="reference internal" href="s.html#term-suballocator"><em class="xref std std-term">suballocators</em></a> are
|
|
involved, but it can lead to an out-of-resource error during a
|
|
<a class="reference internal" href="m.html#term-memory-2"><em class="xref std std-term">memory<sup>(2)</sup></em></a> access; few environments deal with this
|
|
situation gracefully.</p>
|
|
<p class="last">Unix systems such as IRIX and AIX can do this on <a class="reference internal" href="s.html#term-sbrk"><em class="xref std std-term">sbrk</em></a>
|
|
and <a class="reference internal" href="m.html#term-mmap"><em class="xref std std-term">mmap</em></a> calls.</p>
|
|
</dd>
|
|
<dt id="term-overwriting-error">overwriting error</dt>
|
|
<dd><div class="admonition-also-known-as first admonition">
|
|
<p class="first admonition-title">Also known as</p>
|
|
<p class="last"><em>bounds error</em>.</p>
|
|
</div>
|
|
<p>An overwriting or bounds error occurs when the programmer
|
|
intends his program to write to a particular <a class="reference internal" href="b.html#term-block"><em class="xref std std-term">block</em></a> of
|
|
<a class="reference internal" href="m.html#term-memory-1"><em class="xref std std-term">memory<sup>(1)</sup></em></a>, but a program error causes the program to
|
|
write outside the bounds of that block.</p>
|
|
<div class="admonition-see-also last admonition seealso">
|
|
<p class="first admonition-title">See also</p>
|
|
<p class="last"><a class="reference internal" href="f.html#term-fencepost"><em class="xref std std-term">fencepost</em></a>.</p>
|
|
</div>
|
|
</dd>
|
|
</dl>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="sphinxsidebar">
|
|
<div class="sphinxsidebarwrapper">
|
|
<p class="logo"><a href="../index.html">
|
|
<img class="logo" src="../_static/logo.png" alt="Logo"/>
|
|
</a></p>
|
|
<h4>Previous topic</h4>
|
|
<p class="topless"><a href="n.html"
|
|
title="previous chapter">Memory Management Glossary: N</a></p>
|
|
<h4>Next topic</h4>
|
|
<p class="topless"><a href="p.html"
|
|
title="next chapter">Memory Management Glossary: P</a></p><h4>Downloads</h4>
|
|
|
|
<p class="topless">
|
|
<a href="http://www.ravenbrook.com/project/mps/release/1.111.0/">MPS Kit release 1.111.0</a><br>
|
|
<a href="http://www.ravenbrook.com/project/mps/release/">All MPS Kit releases</a>
|
|
</p>
|
|
|
|
<h4>Issues</h4>
|
|
|
|
<p class="topless">
|
|
<a href="http://www.ravenbrook.com/project/mps/issue/?action=list&view=status%3dopen&display=Job:Priority:Title&sort=Priority">Known issues</a><br>
|
|
<a href="http://www.ravenbrook.com/project/mps/issue/?action=fixed&release_fixed=1.111.0">Issues fixed in release 1.111.0</a>
|
|
</p><h4>Contact us</h4>
|
|
|
|
<p class="topless"><a href="mailto:mps-questions@ravenbrook.com">mps-questions@ravenbrook.com</a></p>
|
|
</div>
|
|
</div>
|
|
<div class="clearer"></div>
|
|
</div>
|
|
<div class="related">
|
|
<h3>Navigation</h3>
|
|
<ul>
|
|
<li class="right" style="margin-right: 10px">
|
|
<a href="../genindex.html" title="General Index"
|
|
>index</a></li>
|
|
<li class="right" >
|
|
<a href="p.html" title="Memory Management Glossary: P"
|
|
>next</a> |</li>
|
|
<li class="right" >
|
|
<a href="n.html" title="Memory Management Glossary: N"
|
|
>previous</a> |</li>
|
|
<li><a href="../index.html">Memory Pool System 1.111.0 documentation</a> »</li>
|
|
<li><a href="index.html" >Memory Management Glossary</a> »</li>
|
|
</ul>
|
|
</div>
|
|
<div class="footer">
|
|
© <a href="../copyright.html">Copyright</a> 2013, Ravenbrook Limited.
|
|
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
|
</div>
|
|
</body>
|
|
</html> |