1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-12 22:40:46 -08:00
emacs/mps/manual/html/design/fix.html
Gareth Rees c5f77afc19 Bring html up to date for the mps manual.
Copied from Perforce
 Change: 181433
 ServerID: perforce.ravenbrook.com
2013-04-24 12:21:37 +01:00

166 lines
No EOL
9.2 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>9. The generic fix function &mdash; 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="Design" href="index.html" />
<link rel="next" title="14. The lock module" href="lock.html" />
<link rel="prev" title="8. Finalization" href="finalize.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="lock.html" title="14. The lock module"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="finalize.html" title="8. Finalization"
accesskey="P">previous</a> |</li>
<li><a href="../index.html">Memory Pool System 1.111.0 documentation</a> &raquo;</li>
<li><a href="index.html" accesskey="U">Design</a> &raquo;</li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="the-generic-fix-function">
<span id="design.mps.fix"></span><h1>9. The generic fix function<a class="headerlink" href="#the-generic-fix-function" title="Permalink to this headline"></a></h1>
</div>
<div class="section" id="introduction">
<h1>10. Introduction<a class="headerlink" href="#introduction" title="Permalink to this headline"></a></h1>
<p>Fix is the interface through which the existence of references are
communicated from the MPS client to the MPS. The interface also allows
the value of such references to be changed (this is necessary in order
to implement a moving memory manager).</p>
</div>
<div class="section" id="history">
<h1>11. History<a class="headerlink" href="#history" title="Permalink to this headline"></a></h1>
<p><span class="target" id="design.mps.fix.hist.0"></span><a class="mpstag reference internal" href="#design.mps.fix.hist.0">.hist.0:</a> Incomplete design. Richard Brooksby, 1995-08-25.</p>
<p><span class="target" id="design.mps.fix.hist.1"></span><a class="mpstag reference internal" href="#design.mps.fix.hist.1">.hist.1:</a> Converted from MMInfo database design document.
Richard Brooksby, 2002-06-07.</p>
<p><span class="target" id="design.mps.fix.hist.2"></span><a class="mpstag reference internal" href="#design.mps.fix.hist.2">.hist.2:</a> Converted to reStructuredText. Gareth Rees,
2013-04-14.</p>
</div>
<div class="section" id="architecture">
<h1>12. Architecture<a class="headerlink" href="#architecture" title="Permalink to this headline"></a></h1>
<p><span class="target" id="design.mps.fix.protocol.was-marked"></span><a class="mpstag reference internal" href="#design.mps.fix.protocol.was-marked">.protocol.was-marked:</a> The <tt class="xref c c-type docutils literal"><span class="pre">ScanState</span></tt> has a
<a class="reference internal" href="type.html#Bool" title="Bool"><tt class="xref c c-type docutils literal"><span class="pre">Bool</span></tt></a> <tt class="docutils literal"><span class="pre">wasMarked</span></tt> field. This is used for finalization.</p>
<p><span class="target" id="design.mps.fix.protocol.was-marked.set"></span><a class="mpstag reference internal" href="#design.mps.fix.protocol.was-marked.set">.protocol.was-marked.set:</a> All pool-specific fix methods must
set the <tt class="docutils literal"><span class="pre">wasMarked</span></tt> field in the <tt class="xref c c-type docutils literal"><span class="pre">ScanState</span></tt> that they are
passed.</p>
<p><span class="target" id="design.mps.fix.protocol.was-marked.meaning"></span><a class="mpstag reference internal" href="#design.mps.fix.protocol.was-marked.meaning">.protocol.was-marked.meaning:</a> If the pool-specific fix method
sets the <tt class="docutils literal"><span class="pre">wasMarked</span></tt> field to <tt class="docutils literal"><span class="pre">FALSE</span></tt> it is indicating the object
referred to by the ref (the one that it is supposed to be fixing) has
not previously been marked (ie, this is the first reference to this
object that has been fixed), and that the object was white (in
condemned space).</p>
<p><span class="target" id="design.mps.fix.protocol.was-marked.conservative"></span><a class="mpstag reference internal" href="#design.mps.fix.protocol.was-marked.conservative">.protocol.was-marked.conservative:</a> It is always okay to set
the <tt class="docutils literal"><span class="pre">wasMarked</span></tt> field to <tt class="docutils literal"><span class="pre">TRUE</span></tt>.</p>
<p><span class="target" id="design.mps.fix.protocol.was-marked.finalizable"></span><a class="mpstag reference internal" href="#design.mps.fix.protocol.was-marked.finalizable">.protocol.was-marked.finalizable:</a> The MRG pool
(design.mps.poolmrg) uses the value of the <tt class="docutils literal"><span class="pre">wasMarked</span></tt>
field to determine whether an object is finalizable.</p>
</div>
<div class="section" id="implementation">
<h1>13. Implementation<a class="headerlink" href="#implementation" title="Permalink to this headline"></a></h1>
<p><span class="target" id="design.mps.fix.fix.nailed"></span><a class="mpstag reference internal" href="#design.mps.fix.fix.nailed">.fix.nailed:</a> In a copying collection, a non-ambiguous fix to
a broken heart should be snapped out <em>even if</em> there is a
<tt class="xref c c-macro docutils literal"><span class="pre">RankAMBIG</span></tt> ref to same object (that is, if the broken heart
is nailed); the <tt class="xref c c-macro docutils literal"><span class="pre">RankAMBIG</span></tt> reference must either be stale
(no longer in existence) or bogus.</p>
</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>
<h3><a href="../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">9. The generic fix function</a></li>
<li><a class="reference internal" href="#introduction">10. Introduction</a></li>
<li><a class="reference internal" href="#history">11. History</a></li>
<li><a class="reference internal" href="#architecture">12. Architecture</a></li>
<li><a class="reference internal" href="#implementation">13. Implementation</a></li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="finalize.html"
title="previous chapter">8. Finalization</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="lock.html"
title="next chapter">14. The lock module</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&amp;view=status%3dopen&amp;display=Job:Priority:Title&amp;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="lock.html" title="14. The lock module"
>next</a> |</li>
<li class="right" >
<a href="finalize.html" title="8. Finalization"
>previous</a> |</li>
<li><a href="../index.html">Memory Pool System 1.111.0 documentation</a> &raquo;</li>
<li><a href="index.html" >Design</a> &raquo;</li>
</ul>
</div>
<div class="footer">
&copy; <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>