1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-26 23:31:55 -08:00

Update tag references in design documents so that they work in the design directory, and in the manual.

Copied from Perforce
 Change: 192748
 ServerID: perforce.ravenbrook.com
This commit is contained in:
Gareth Rees 2016-11-11 10:20:02 +00:00
parent 30d5a523b8
commit c14d96d9ec
25 changed files with 62 additions and 62 deletions

View file

@ -153,15 +153,15 @@ _`.lim.vm`: Maps all reserved addresses into main memory (see
design.mps.vm.impl.an.reserve_), thus using more main memory than a
platform-specific implementation.
.. _design.mps.lock.impl.an: lock#impl.an
.. _design.mps.prmc.impl.an.fault: prmc#impl.an.fault
.. _design.mps.prmc.impl.an.suspend: prmc#impl.an.suspend
.. _design.mps.prot.impl.an.sync: prot#impl.an.sync
.. _design.mps.prot.impl.an.sync.issue: prot#impl.an.sync.issue
.. _design.mps.sp.issue.an: sp#issue.an
.. _design.mps.ss.impl.an: ss#impl.an
.. _design.mps.thread-manager.impl.an.single: thread-manager#impl.an.single
.. _design.mps.vm.impl.an.reserve: vm#impl.an.reserve
.. _design.mps.lock.impl.an: lock#impl-an
.. _design.mps.prmc.impl.an.fault: prmc#impl-an-fault
.. _design.mps.prmc.impl.an.suspend: prmc#impl-an-suspend
.. _design.mps.prot.impl.an.sync: prot#impl-an-sync
.. _design.mps.prot.impl.an.sync.issue: prot#impl-an-sync-issue
.. _design.mps.sp.issue.an: sp#issue-an
.. _design.mps.ss.impl.an: ss#impl-an
.. _design.mps.thread-manager.impl.an.single: thread-manager#impl-an-single
.. _design.mps.vm.impl.an.reserve: vm#impl-an-reserve

View file

@ -308,7 +308,7 @@ If this field is ``TRUE``, then the value of ``p`` is a ``Seg``. See
design.mps.type.bool.bitfield_ for why this is declared using the
``BOOLFIELD`` macro.
.. _design.mps.type.bool.bitfield: type#bool.bitfield
.. _design.mps.type.bool.bitfield: type#bool-bitfield
_`.tract.field.base`: The base field contains the base address of the
memory represented by the tract.

View file

@ -52,7 +52,7 @@ condemned sets to coincide with zone stripes.
_`.overview.gc.tract`: A fast translation from addresses to tract.
(See design.mps.arena.req.fun.trans_.)
.. _design.mps.arena.req.fun.trans: arena#req.fun.trans
.. _design.mps.arena.req.fun.trans: arena#req-fun-trans
Notes
@ -63,7 +63,7 @@ _`.note.refset`: Some of this document simply assumes that RefSets
the solution for design.mps.arena.req.fun.set_. It's a lot simpler
that way. Both to write and understand.
.. _design.mps.arena.req.fun.set: arena#req.fun.set
.. _design.mps.arena.req.fun.set: arena#req-fun-set
Requirements
@ -186,7 +186,7 @@ only valid if it is allocated to a pool. If it is not allocated to a
pool, the fields of the tract are used for other purposes. (See
design.mps.arena.tract.field.pool_)
.. _design.mps.arena.tract.field.pool: arena#tract.field.pool
.. _design.mps.arena.tract.field.pool: arena#tract-field-pool
_`.table.alloc`: The alloc table is a simple bit table (implemented
using the BT module, design.mps.bt_).

View file

@ -182,7 +182,7 @@ extra field to the buffer. The convenience macro
``DEFINE_BUFFER_CLASS()`` may be used to define subclasses of buffer
classes. See design.mps.protocol.int.define-special_.
.. _design.mps.protocol.int.define-special: protocol#int.define-special
.. _design.mps.protocol.int.define-special: protocol#int-define-special
_`.replay`: To work with the allocation replayer (see
design.mps.telemetry.replayer_), the buffer class has to emit an event

View file

@ -60,7 +60,7 @@ _`.impl.scan`: An object is determined to be finalizable if it is
fixed at rank FINAL for a trace, and was not fixed at any lower rank
for that trace. See design.mps.poolmrg.scan.wasold_.
.. _design.mps.poolmrg.scan.wasold: poolmrg#scan.wasold
.. _design.mps.poolmrg.scan.wasold: poolmrg#scan-wasold
_`.impl.message`: When an object is determined to be finalizable, a
message for that object is posted to the arena's message queue.

View file

@ -130,7 +130,7 @@ _`.test`: The following testing will be performed on this module:
_`.test.land`: A generic test for land implementations. See
design.mps.land.test_.
.. _design.mps.land.test: land#design.mps.land.test
.. _design.mps.land.test: land#design-mps-land-test
_`.test.pool`: Two pools (MVT_ and MVFF_) use free lists as a fallback
when low on memory. These are subject to testing in development, QA,

View file

@ -74,20 +74,20 @@ to protect the data structure allowing multiple arenas to coordinate
handling of protection faults: see
design.mps.thread-safety.sol.global.mutable_.)
.. _design.mps.thread-safety.sol.global.mutable: thread-safety#sol.global.mutable
.. _design.mps.thread-safety.sol.global.mutable: thread-safety#sol-global-mutable
_`.req.global.recursive`: Provide a global recursive lock. (This is
required to protect protocol class initialization: see
design.mps.thread-safety.sol.global.once_.)
.. _design.mps.thread-safety.sol.global.once: thread-safety#sol.global.once
.. _design.mps.thread-safety.sol.global.once: thread-safety#sol-global-once
_`.req.deadlock.not`: There is no requirement to provide protection
against deadlock. (Clients are able to avoid deadlock using
traditional strategies such as ordering of locks; see
design.mps.thread-safety.sol.deadlock_.)
.. _design.mps.thread-safety.sol.deadlock: thread-safety#sol.deadlock
.. _design.mps.thread-safety.sol.deadlock: thread-safety#sol-deadlock
Interface

View file

@ -165,7 +165,7 @@ _`.type.finalization.semantics`: A finalization message indicates that
an object has been discovered to be finalizable (see
design.mps.poolmrg.def.final.object_ for a definition of finalizable).
.. _design.mps.poolmrg.def.final.object: poolmrg#def.final.object
.. _design.mps.poolmrg.def.final.object: poolmrg#def-final-object
_`.type.finalization.ref`: The accessor function
``mps_message_finalization_ref()`` retrieves the reference to the
@ -333,7 +333,7 @@ the function the message fields must not be manipulated except from
the message's class's method functions (that is, you mustn't poke
about with the ``queueRing`` field in particular).
.. _design.mps.ring.def.singleton: ring#def.singleton
.. _design.mps.ring.def.singleton: ring#def-singleton
``void MessageEmpty(Arena arena)``

View file

@ -436,7 +436,7 @@ split and merge should not be written in such a way that they might
detect failure after calling the next method, unless they have reason
to know that the bit table allocations will not fail.
.. _design.mps.seg.split-merge.fail.anti.no: seg#split-merge.fail.anti.no
.. _design.mps.seg.split-merge.fail.anti.no: seg#split-merge-fail-anti-no
Testing

View file

@ -175,7 +175,7 @@ which the structure is::
Sig sig;
}
.. _design.mps.seg.over.hierarchy.gcseg: seg#over.hierarchy.gcseg
.. _design.mps.seg.over.hierarchy.gcseg: seg#over-hierarchy-gcseg
_`.awlseg.bt`: The mark, alloc, and scanned fields are bit-tables (see
design.mps.bt_). Each bit in the table corresponds to a a single
@ -417,7 +417,7 @@ perform another pass (see `.fun.scan.pass`_ above).
_`.fun.fix`: ``ss->wasMarked`` is set to ``TRUE`` (clear compliance
with design.mps.fix.protocol.was-marked.conservative_).
.. _design.mps.fix.protocol.was-marked.conservative: fix#protocol.was-marked.conservative
.. _design.mps.fix.protocol.was-marked.conservative: fix#protocol-was-marked-conservative
If the rank (``ss->rank``) is ``RankAMBIG`` then fix returns
immediately unless the reference is aligned to the pool alignment.

View file

@ -183,7 +183,7 @@ registered for finalization. This protocol is handled by the arena
module on behalf of finalization. see
design.mps.finalize.int.finalize_.
.. _design.mps.finalize.int.finalize: finalize#int.finalize
.. _design.mps.finalize.int.finalize: finalize#int-finalize
Finalizer execution
@ -204,7 +204,7 @@ _`.protocol.life`: An instance of PoolClassMRG is needed in order to
support finalization, it is called the "final" pool and is attached to
the arena (see design.mps.finalize.int.arena.struct_).
.. _design.mps.finalize.int.arena.struct: finalize#int.arena.struct
.. _design.mps.finalize.int.arena.struct: finalize#int-arena-struct
_`.protocol.life.birth`: The final pool is created lazily by
``ArenaFinalize()``.

View file

@ -793,8 +793,8 @@ attempts to flush blocks from the free list back to the CBS. See
design.mps.freelist_ for the design and implementation of the free
list.
.. _design.mps.cbs.function.cbs.delete.fail: cbs#function.cbs.delete.fail
.. _design.mps.cbs.function.cbs.insert.fail: cbs#function.cbs.insert.fail
.. _design.mps.cbs.function.cbs.delete.fail: cbs#function-cbs-delete-fail
.. _design.mps.cbs.function.cbs.insert.fail: cbs#function-cbs-insert-fail
.. _design.mps.freelist: freelist

View file

@ -68,7 +68,7 @@ scan all roots in the context of a thread that has been suspended by
the thread manager. (This is necessary for conservative garbage
collection to work. See design.mps.thread-manager.if.scan_.)
.. _design.mps.thread-manager.if.scan: thread-manager#if.scan
.. _design.mps.thread-manager.if.scan: thread-manager#if-scan
Interface
@ -94,7 +94,7 @@ by the thread manager. This structure should be declared in a header
so that it can be inlined in the ``Thread`` structure if necessary.
See design.mps.thread-manager.if.thread_.
.. _design.mps.thread-manager.if.thread: thread-manager#if.thread
.. _design.mps.thread-manager.if.thread: thread-manager#if-thread
``Bool MutatorContextCheck(MutatorContext context)``
@ -164,13 +164,13 @@ _`.impl.an.fault`: Compatible only with the generic memory protection
module (design.mps.prot.impl.an_) where there are no protection
faults.
.. _design.mps.prot.impl.an: prot#impl.an
.. _design.mps.prot.impl.an: prot#impl-an
_`.impl.an.suspend`: Compatible only with the generic thread manager
module (design.mps.thread-manager.impl.an_) where there is only one
thread, and so no threads are suspended.
.. _design.mps.thread-manager.impl.an: thread-manager#impl.an
.. _design.mps.thread-manager.impl.an: thread-manager#impl-an
Posix implementation

View file

@ -66,8 +66,8 @@ by decoding the context of the fault (see
design.mps.prmc.req.fault.addr_ and design.mps.prmc.req.fault.access_)
and calling ``ArenaAccess()``.
.. _design.mps.prmc.req.fault.addr: prmc#req.fault.addr
.. _design.mps.prmc.req.fault.access: prmc#req.fault.access
.. _design.mps.prmc.req.fault.addr: prmc#req-fault-addr
.. _design.mps.prmc.req.fault.access: prmc#req-fault-access
Interface
@ -131,7 +131,7 @@ protection, otherwise there is an infinite loop here. This is
therefore not compatible with implementations of the protection
mutator context module that support single-stepping of accesses (see design.mps.prmc.req.fault.step_).
.. _design.mps.prmc.req.fault.step: prmc#req.fault.step
.. _design.mps.prmc.req.fault.step: prmc#req-fault-step
_`.impl.ix`: POSIX implementation. See design.mps.protix_.

View file

@ -67,7 +67,7 @@ and read accesses are allowed, this is done by setting the protection
of the page to ``PROT_READ|PROT_EXEC``. Otherwise (all access are
okay), the protection is set to ``PROT_READ|PROT_WRITE|PROT_EXEC``.
.. _design.mps.prot.if.set: prot#if.set
.. _design.mps.prot.if.set: prot#if-set
_`.fun.set.assume.mprotect`: We assume that the call to ``mprotect()``
always succeeds.
@ -98,7 +98,7 @@ as required by the design (see
design.mps.pthreadext.req.suspend.protection_). The signal handlers
simply nest at top of stack.
.. _design.mps.pthreadext.req.suspend.protection: pthreadext#req.suspend.protection
.. _design.mps.pthreadext.req.suspend.protection: pthreadext#req-suspend-protection
_`.threads.async`: POSIX imposes some restrictions on signal handler
functions (see design.mps.pthreadext.anal.signal.safety_). Basically
@ -108,7 +108,7 @@ are known to be "async-signal safe". However, if it's known that the
signal didn't happen inside a POSIX function, then it is safe to call
arbitrary POSIX functions inside a handler.
.. _design.mps.pthreadext.anal.signal.safety: pthreadext#anal.signal.safety
.. _design.mps.pthreadext.anal.signal.safety: pthreadext#anal-signal-safety
_`.threads.async.protection`: If the signal handler is invoked because
of an MPS access, then we know the access must have been caused by

View file

@ -547,7 +547,7 @@ _`.impl.define-class.lock`: The ``DEFINE_CLASS`` macro ensures that
each class is initialized at most once (even in multi-threaded
programs) by claiming the global recursive lock (see design.mps.thread-safety.arch.global.recursive_).
.. _design.mps.thread-safety.arch.global.recursive: thread-safety#arch.global.recursive
.. _design.mps.thread-safety.arch.global.recursive: thread-safety#arch-global-recursive
_`.impl.derived-names`: The ``DEFINE_CLASS()`` macro derives some
additional names from the class name as part of it's implementation.

View file

@ -38,7 +38,7 @@ The reason that ``ss.unfixedSummary`` is always a subset of the
previous summary is due to an "optimization" which has not been made
in ``TraceFix``. See design.mps.trace.fix.fixed.all_.
.. _design.mps.trace.fix.fixed.all: trace#fix.fixed.all
.. _design.mps.trace.fix.fixed.all: trace#fix-fixed-all
Partial scans

View file

@ -246,7 +246,7 @@ _`.method.split.next`: A split method should always call the next
method, either before or after any class-specific code (see
design.mps.protocol.overview.next-method_).
.. _design.mps.protocol.overview.next-method: protocol#overview.next-method
.. _design.mps.protocol.overview.next-method: protocol#overview-next-method
_`.method.split.accounting`: If ``seg`` belongs to a generation in a
chain, then the pool generation accounting must be updated. In the
@ -268,7 +268,7 @@ _`.method.merge.next`: A merge method should always call the next
method, either before or after any class-specific code (see
design.mps.protocol.overview.next-method_).
.. _design.mps.protocol.overview.next-method: protocol#overview.next-method
.. _design.mps.protocol.overview.next-method: protocol#overview-next-method
_`.method.merge.accounting`: If ``seg`` belongs to a generation in a
chain, then the pool generation accounting must be updated. In the
@ -298,7 +298,7 @@ before calling the next method, the appropriate anti-method must be
used (see design.mps.protocol.guide.fail.after-next_). Split methods
are anti-methods for merge methods, and vice-versa.
.. _design.mps.protocol.guide.fail.after-next: protocol#guide.fail.after-next
.. _design.mps.protocol.guide.fail.after-next: protocol#guide-fail-after-next
_`.split-merge.fail.anti.constrain`: In general, care should be taken
when writing split and merge methods to ensure that they really are

View file

@ -28,7 +28,7 @@ _`.other`: The thread manager module is responsible for scanning the
control stack and registers of *other* threads. See
design.mps.thread-manager.if.scan_.
.. _design.mps.thread-manager.if.scan: thread-manager#if.scan
.. _design.mps.thread-manager.if.scan: thread-manager#if-scan
Requirements

View file

@ -117,7 +117,7 @@ by ``mps_thread_dereg()``. It can't use ``AVER(TESTT(Thread,
thread))``, as recommended by design.mps.sig.check.arg.unlocked_,
since ``Thread`` is an opaque type.
.. _design.mps.sig.check.arg.unlocked: sig#check.arg.unlocked
.. _design.mps.sig.check.arg.unlocked: sig#check-arg-unlocked
``Arena ThreadArena(Thread thread)``
@ -210,18 +210,18 @@ specially by the POSIX thread extensions. See
design.mps.pthreadext.req.suspend.multiple_ and
design.mps.pthreadext.req.resume.multiple_.
.. _design.mps.pthreadext.req.suspend.multiple: pthreadext#req.suspend.multiple
.. _design.mps.pthreadext.req.resume.multiple: pthreadext#req.resume.multiple
.. _design.mps.pthreadext.req.suspend.multiple: pthreadext#req-suspend-multiple
.. _design.mps.pthreadext.req.resume.multiple: pthreadext#req-resume-multiple
_`.impl.ix.suspend`: ``ThreadRingSuspend()`` calls
``PThreadextSuspend()``. See design.mps.pthreadext.if.suspend_.
.. _design.mps.pthreadext.if.suspend: pthreadext#if.suspend
.. _design.mps.pthreadext.if.suspend: pthreadext#if-suspend
_`.impl.ix.resume`: ``ThreadRingResume()`` calls
``PThreadextResume()``. See design.mps.pthreadext.if.resume_.
.. _design.mps.pthreadext.if.resume: pthreadext#if.resume
.. _design.mps.pthreadext.if.resume: pthreadext#if-resume
_`.impl.ix.scan.current`: ``ThreadScan()`` calls ``StackScan()`` if
the thread is current.

View file

@ -172,8 +172,8 @@ design.mps.lock.req.global.binary_) that protects mutable data shared
between all arenas (that is, the arena ring lock: see
design.mps.arena.static.ring.lock_).
.. _design.mps.lock.req.global.binary: lock#req.global.binary
.. _design.mps.arena.static.ring.lock: arena#static.ring.lock
.. _design.mps.lock.req.global.binary: lock#req-global-binary
.. _design.mps.arena.static.ring.lock: arena#static-ring-lock
_`.sol.global.once`: There is a global recursive lock (see
design.mps.lock.req.global.recursive_) that protects static data which
@ -183,8 +183,8 @@ claims the global recursive lock, checks to see if the data structure
has been initialized yet, and does so if necessary (see
design.mps.protocol.impl.define-class.lock_).
.. _design.mps.lock.req.global.recursive: lock#req.global.recursive
.. _design.mps.protocol.impl.define-class.lock: protocol#impl.define-class.lock
.. _design.mps.lock.req.global.recursive: lock#req-global-recursive
.. _design.mps.protocol.impl.define-class.lock: protocol#impl-define-class-lock
_`.sol.deadlock`: A strict ordering is required between the global and
arena locks to prevent deadlock. The binary global lock may not be
@ -194,7 +194,7 @@ Each arena lock is independent of all other arena locks; that is, a
thread may not attempt to claim more than one arena lock at a time.
See design.mps.arena.lock.avoid_.
.. _design.mps.arena.lock.avoid: arena#lock.avoid
.. _design.mps.arena.lock.avoid: arena#lock-avoid
_`.sol.check`: The MPS interface design requires that a function must
check the signatures on the data structures pointed to by its
@ -205,8 +205,8 @@ checking interface provides a ``TESTT()`` macro that checks the
signature in a thread-safe way (see
design.mps.sig.check.arg.unlocked_).
.. _design.mps.sig.check.arg: sig#check.arg
.. _design.mps.sig.check.arg.unlocked: sig#check.arg.unlocked
.. _design.mps.sig.check.arg: sig#check-arg
.. _design.mps.sig.check.arg.unlocked: sig#check-arg-unlocked
Document History

View file

@ -111,7 +111,7 @@ There is an attribute field in the pool class (``PoolClassStruct``)
which declares the attributes of that class. See
design.mps.pool.field.attr_.
.. _design.mps.pool.field.attr: pool#field.attr
.. _design.mps.pool.field.attr: pool#field-attr
``typedef int Bool``
@ -553,7 +553,7 @@ _`.traceid`: A ``TraceId`` is an unsigned integer which is less than
is used to index into the tables and bitfields that record the state
of that trace. See design.mps.trace.instance.limit_.
.. _design.mps.trace.instance.limit: trace#instance.limit
.. _design.mps.trace.instance.limit: trace#instance-limit
``typedef unsigned TraceSet``
@ -632,7 +632,7 @@ _`.word.source`: ``Word`` is derived from the macro ``MPS_T_WORD``
which is declared in impl.h.mpstd according to the target platform
(design.mps.config.pf.word_).
.. _design.mps.config.pf.word: config#pf.word
.. _design.mps.config.pf.word: config#pf-word
_`.word.conv.c`: ``Word`` is converted to ``mps_word_t`` in the MPS C
Interface.

View file

@ -95,7 +95,7 @@ expansion of the macro ``MPS_PROD_STRING`` defined by ``config.h``
(impl.h.config). Note that there is now only one product, so this is
always ``"mps"`` (see design.mps.config.req.prod_).
.. _design.mps.config.req.prod: config#req.prod
.. _design.mps.config.req.prod: config#req-prod
_`.impl.platform`: The string containing the name of the platform is
the expansion of the macro ``MPS_PF_STRING`` defined by ``mpstd.h``

View file

@ -38,7 +38,7 @@ _`.req.granularity`: The virtual mapping module must report the
necessary for the arena to be able to portably determine its grain
size; see design.mps.arena.def.grain_.)
.. _design.mps.arena.def.grain: arena#def.grain
.. _design.mps.arena.def.grain: arena#def-grain
_`.req.reserve`: The *reserve* operation must reserves a chunk of
address space.

View file

@ -43,7 +43,7 @@ func = re.compile(r'``([A-Za-z][A-Za-z0-9_]+\(\))``')
typename = re.compile(r'``({0}|[A-Z][A-Za-z0-9_]*(?:Class|Struct|Method)|mps_[a-z_]+_[stu])``(?: )?'
.format('|'.join(map(re.escape, TYPES.split()))))
design_ref = re.compile(r'^( *\.\. _design\.mps\.(?:[^:\n]+): (?:[^#:\n]+))$', re.MULTILINE)
design_frag_ref = re.compile(r'^( *\.\. _design\.mps\.([^:\n]+)\.([^:\n]+): (?:[^#:\n]+))#\3$', re.MULTILINE)
design_frag_ref = re.compile(r'^( *\.\. _design\.mps\.([^:\n]+)\.([^:\n]+): (?:[^#:\n]+))#(.+)$', re.MULTILINE)
history = re.compile(r'^Document History\n.*',
re.MULTILINE | re.IGNORECASE | re.DOTALL)