Ravenbrook / Projects / Memory Pool System / Master Product Sources / Design Documents

Memory Pool System Project


MPS Internal Tests

This document contains a guide to the MPS Internal Tests. There is no historical initial design, but there is a placeholder for early ideas and discussions: initial ideas. References, History, Copyright and License are at the end.


Guide

Readership: any MPS developer. Not confidential.

zmess.c

Tests message lifecycle, and finalization (by using finalization messages).

zcoll.c

Tests collection scheduling, and collection feedback.

Finalization Tests

There are three main ones:

finalcv.c
Oldest. Registers a few objects (for finalization) and pseudorandomly makes them unreachable, deregisters them, etc. Churns to provoke minor (nursery) collection.
finaltest.c
Uses newer fmtdytst facilities. Creates a large binary tree, and registers every node. Drops top ref, requests collection, and counts the messages.
fin1658a.c -- deleted
[Subsumed into and replaced by zmess.c, 2009-02-17]. fin1658a.c was a single-issue test: see job001658. Drops refs and requests collection. Verifies that all non-E-reachable registered objects are finalized in a single collection, even if there are >1 segs of poolmrg guardians.

There's also expt825.c, which verifies that protection expose/remember works correctly for poolmrg (scanned but not GC'd segs); see job000825.


Initial Ideas

There never was an initial design document. This is a placeholder for links to early ideas and discussions.


A. References

B. Document History

2008-12-04 RHSK Create. Describe finalization tests.
2010-03-03 RHSK Correction: it's fin1658a.c and job001658, not 1638.
2010-03-03 RHSK Add zmess.c, zcoll.c. zmess.c subsumes and replaces fin1658a.c.

C. Copyright and License

This document is copyright © 2008, 2010 Ravenbrook Limited. All rights reserved. This is an open source license. Contact Ravenbrook for commercial licensing options.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. Redistributions in any form must be accompanied by information on how to obtain complete source code for the this software and any accompanying software that uses this software. The source code must either be included in the distribution or be available for no more than the cost of distribution plus a nominal fee, and must be freely redistributable under reasonable conditions. For an executable file, complete source code means the source code for all modules it contains. It does not include source code for modules or files that typically accompany the major components of the operating system on which the executable file runs.

This software is provided by the copyright holders and contributors "as is" and any express or implied warranties, including, but not limited to, the implied warranties of merchantability, fitness for a particular purpose, or non-infringement, are disclaimed. In no event shall the copyright holders and contributors be liable for any direct, indirect, incidental, special, exemplary, or consequential damages (including, but not limited to, procurement of substitute goods or services; loss of use, data, or profits; or business interruption) however caused and on any theory of liability, whether in contract, strict liability, or tort (including negligence or otherwise) arising in any way out of the use of this software, even if advised of the possibility of such damage.


$Id: //info.ravenbrook.com/project/mps/branch/2013-05-01/keyword-arguments/design/tests/index.html#2 $

Ravenbrook / Projects / Memory Pool System / Master Product Sources / Design Documents