Skip to content

Commit 5078ce1

Browse files
committed
Update the MPS Manual for compatibility with Sphinx 3.
1 parent e873ab4 commit 5078ce1

29 files changed

Lines changed: 142 additions & 123 deletions

design/abq.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ Interface
5151
client structures: clients must not depend on its implementation
5252
details.
5353

54-
``ABQInit(Arena arena, ABQ abq, void *owner, Count elements, Size elementSize)``
54+
``void ABQInit(Arena arena, ABQ abq, void *owner, Count elements, Size elementSize)``
5555

5656
Initialize the queue ``abq``. The parameter ``arena`` is the arena
5757
whose control pool should be used to allocate the memory for the

design/bt.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -518,8 +518,8 @@ for the following two functions::
518518
return (i>>5) + (i&31);
519519
}
520520

521-
``ACT_ON_RANGE(Index base, Index limit, single_action, bits_action, word_action)``
522-
``ACT_ON_RANGE_HIGH(Index base, Index limit, single_action, bits_action, word_action)``
521+
``ACT_ON_RANGE(base, limit, single_action, bits_action, word_action)``
522+
``ACT_ON_RANGE_HIGH(base, limit, single_action, bits_action, word_action)``
523523

524524
_`.iteration`: Many of the following functions involve iteration over
525525
ranges in a Bit Table. This is performed on whole words rather than

design/buffer.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -544,7 +544,7 @@ itself.
544544
The pool class's ``bufferDestroy()`` method is called and then the
545545
buffer structure is uninitialized and freed.
546546

547-
``BufferCheck(Buffer buffer)``
547+
``Bool BufferCheck(Buffer buffer)``
548548

549549
_`.method.check`: The check method is straightforward, the non-trivial dependencies checked are:
550550

@@ -582,7 +582,7 @@ between a reserve and commit. The result is only reliable if the
582582
client is not currently using the buffer, since it may update the
583583
alloc and init pointers asynchronously.
584584

585-
``mps_ap_t (BufferAP)(Buffer buffer)``
585+
``mps_ap_t BufferAP(Buffer buffer)``
586586

587587
Returns the ``APStruct`` substructure of a buffer.
588588

@@ -653,7 +653,7 @@ again for any purpose.
653653
Some classes of pool may cause commit to fail under rare
654654
circumstances.
655655

656-
``BufferTrip(Buffer buffer, Addr p, Size size)``
656+
``void BufferTrip(Buffer buffer, Addr p, Size size)``
657657

658658
_`.method.trip`: Act on a tripped buffer. The pool which owns a buffer
659659
may asynchronously set the buffer limit to zero in order to get

design/clock.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,13 @@ macro must assign a timestamp to ``lvalue`` with the value ``(high
6060
_`.if.get`: Assign an ``EventClock`` timestamp for the current time to
6161
``lvalue``, which is an lvalue with type ``EventClock``.
6262

63-
``EVENT_CLOCK_PRINT(FILE *stream, EventClock clock)``
63+
``EVENT_CLOCK_PRINT(stream, clock)``
6464

6565
_`.if.print`: Write the value of ``clock`` to the standard C output
6666
file handle ``stream`` as 16 hexadecimal digits (with leading zeros,
6767
and capital letters A to F).
6868

69-
``EVENT_CLOCK_WRITE(mps_lib_FILE *stream, EventClock clock)``
69+
``EVENT_CLOCK_WRITE(stream, clock)``
7070

7171
_`.if.write`: Write the value of ``clock`` to the output stream
7272
``stream`` as 16 hexadecimal digits (with leading zeros, and capital

design/fix.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ object referred to by the ref (the one that it is supposed to be
3232
fixing) has not previously been marked (that is, this is the first
3333
reference to this object that has been fixed), and that the object was
3434
white (that is, in condemned space), it should (but need not) set the
35-
field to ``FALSE`` in the passed ``ScanState````wasMarked`` .
35+
``wasMarked`` field to ``FALSE`` in the passed ``ScanState``.
3636

3737
_`.was-marked.otherwise`: Otherwise, the fix method must
3838
leave the ``wasMarked`` field unchanged.

design/interface-c.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ from `mail.richard.1996-08-07.09-49`_.
213213
``COMPATLVALUE(lvalue1, lvalue2)``
214214

215215
_`.check.types.compat.lvalue`: This macro checks the assignment
216-
compatibility of two lvalues. It uses ``sizeof()`` to ensure that the
216+
compatibility of two lvalues. It uses ``sizeof`` to ensure that the
217217
assignments have no effect. ::
218218

219219
#define COMPATLVALUE(lv1, lv2) \
@@ -224,7 +224,7 @@ assignments have no effect. ::
224224
_`.check.types.compat.type`: This macro checks that two types are
225225
assignment-compatible and equal in size. The hack here is that it
226226
generates an lvalue for each type by casting zero to a pointer to the
227-
type. The use of ``sizeof()`` avoids the undefined behaviour that
227+
type. The use of ``sizeof`` avoids the undefined behaviour that
228228
would otherwise result from dereferencing a null pointer. ::
229229

230230
#define COMPATTYPE(t1, t2) \

design/locus.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ specification to place the new allocation immediately above/below a
401401
given tract; if that is not possible, it returns ``ResFAIL`` (this
402402
will make it useful for reallocation functionality).
403403

404-
``ArenaSetTotalLoci(Arena arena, Size nLoci, Size nZoneGroups)``
404+
``void ArenaSetTotalLoci(Arena arena, Size nLoci, Size nZoneGroups)``
405405

406406
_`.function.set-total`: A function to tell the arena the expected
407407
number of (non-miscible client) loci, and of zone groups.

design/object-debug.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,11 @@ fenceposts around an object. The ``NULL`` method checks tails.
342342
_`.interface.tags.alloc`: Two functions to extend the existing
343343
``mps_alloc()`` (request.???.??? proposes to remove the varargs)
344344

345-
``void (*mps_objects_step_t)(mps_addr_t addr, size_t size, mps_fmt_t format, mps_pool_t pool, void *tag_data, void *p)``
345+
``typedef void (*mps_objects_step_t)(mps_addr_t addr, size_t size, mps_fmt_t format, mps_pool_t pool, void *tag_data, void *p)``
346+
347+
_`.interface.tags.walker.type`: Type of walker function for
348+
``mps_pool_walk()`` and ``mps_arena_walk()``.
349+
346350
``void mps_pool_walk(mps_arena_t arena, mps_pool_t pool, mps_objects_step_t step, void *p)``
347351
``void mps_arena_walk(mps_arena_t arena, mps_objects_step_t step, void *p)``
348352

design/prmc.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ protection module can single-step the instruction which is causing the
124124
fault. Return ``TRUE`` if ``MutatorContextStepInstruction()`` is
125125
capable of single-stepping the instruction, or ``FALSE`` if not.
126126

127-
``Bool Res MutatorContextStepInstruction(MutatorContext context)``
127+
``Res MutatorContextStepInstruction(MutatorContext context)``
128128

129129
_`.if.step`: Single-step the instruction which is causing the fault.
130130
Update the mutator context according to the emulation or execution of

design/ring.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ parent-children rings it returns the number of children.
122122
Iteration
123123
.........
124124

125-
``RING_FOR(Ring node, Ring ring, Ring next)``
125+
``RING_FOR(node, ring, next)``
126126

127127
_`.for`: A macro is used for iterating over the elements in a ring.
128128
This macro is called ``RING_FOR()``. ``RING_FOR()`` takes three arguments.
@@ -163,11 +163,11 @@ Element access
163163

164164
_`.next`: ``RingNext()`` returns the next node in the ring.
165165

166-
``Ring (RingPrev)(Ring ring)``
166+
``Ring RingPrev(Ring ring)``
167167

168168
_`.prev`: ``RingPrev()`` returns the previous node in the ring.
169169

170-
``RING_ELT(type, field, Ring node)``
170+
``RING_ELT(type, field, node)``
171171

172172
_`.elt`: ``RING_ELT()`` is a macro that converts a pointer to a ring
173173
structure into a pointer to the enclosing parent structure.
@@ -182,17 +182,17 @@ result is a pointer to the enclosing structure.
182182
Append / Remove
183183
...............
184184

185-
``void RingAppend(Ring ring, Ring new)``
185+
``void RingAppend(ring, new)``
186186

187187
_`.append`: ``RingAppend()`` appends a singleton ring to a ring (such
188188
that the newly added element will be last in the iteration sequence).
189189

190-
``void (RingInsert)(Ring ring, Ring new)``
190+
``void RingInsert(Ring ring, Ring new)``
191191

192192
_`.insert`: ``RingInsert()`` adds a singleton ring to a ring (such that
193193
the newly added element will be first in the iteration sequence).
194194

195-
``void (RingRemove)(Ring old)``
195+
``void RingRemove(Ring old)``
196196

197197
_`.remove`: ``RingRemove()`` removes an element from a ring. The newly
198198
removed element becomes a singleton ring. It is an error for the

0 commit comments

Comments
 (0)