MMgr v1.0.0
Zero-heap memory manager in C11. One borrowed buffer, carved by asserted offset.
Loading...
Searching...
No Matches
praet_procurator.h File Reference

Which states and transitions a run actually reached. More...

Go to the source code of this file.

Macros

#define PRAET_OPTIMIZE
 Whether a run records the work it did, on top of the states it reached.
#define PRAET_PROCURATOR
 Whether a run records the states and transitions it reached.
#define praet_procurator_transitus(channel_, was_, now_)
 Expands to nothing where PRAET_PROCURATOR is 0.
#define praet_procurator_report()
 Expands to nothing where PRAET_PROCURATOR is 0.
#define praet_procurator_opus(kind_)
 Expands to nothing where PRAET_OPTIMIZE is 0.

Detailed Description

Which states and transitions a run actually reached.

Author
dstroy0 (Douglas Quigg) dquig.nosp@m.g123.nosp@m.@gmai.nosp@m.l.co.nosp@m.m
Date
2026-09-01
Note
The examination arm. The correctness arm says every case passed, and that says nothing about which of the machine's states and transitions any case walked through. A four state core with eight statuses has more paths than a suite this size can cover by accident, and so the ones it misses are worth knowing before any of it reaches a part.
Reports and does not gate. A transition nothing reached is a hole in the cases, and whether it is worth filling is a reading of the report and not a build failure. The optimization arm is this same instrument carrying timings.
Off unless PRAET_PROCURATOR is 1, and every entry is then a macro expanding to nothing. A build that did not ask for it carries no counter and no call.
Declared here and defined in the suite. The one function that writes a flag word calls these, and the counters and the table they print belong to a run of the suite, at test/integration/test_praet_correctness/praet_procurator.c.
Warning
A build setting PRAET_PROCURATOR to 1 links against those definitions and fails to link without them. A shipping image has no reason to set it.
Not a knob praet_iudex.h asks about. Every knob there describes the image a caller ships; this describes a run of the suite, the harness's business and not the caller's.

Definition in file praet_procurator.h.

Macro Definition Documentation

◆ PRAET_OPTIMIZE

#define PRAET_OPTIMIZE

Whether a run records the work it did, on top of the states it reached.

Note
The optimization arm, and it is the examination arm carrying more counters. It records work: entries called, channels walked, times the poll short circuited, times the port was asked anything, and the bytes of state a context costs.
No times, and none deliberately. A count of work is the same on every run of one build, and so it is a fact a host can state. What that work costs is a property of a part, and a number taken here would be a number about this machine dressed as a number about the library.
Reports and does not gate, the same as the examination arm. A count that grew is worth reading and is not a build failure, because whether it matters is measured somewhere else.

Definition at line 49 of file praet_procurator.h.

◆ PRAET_PROCURATOR

#define PRAET_PROCURATOR

Whether a run records the states and transitions it reached.

Note
Turned on by PRAET_OPTIMIZE as well, since the work counts are read beside the states they were spent reaching and a report with one half missing says less than either half alone.

Definition at line 66 of file praet_procurator.h.

◆ praet_procurator_transitus

#define praet_procurator_transitus ( channel_,
was_,
now_ )

Expands to nothing where PRAET_PROCURATOR is 0.

Parameters
channel_Channel whose word changed, discarded.
was_The word before, discarded.
now_The word after, discarded.
Note
Casts each argument to void, which keeps a build without the instrument from warning about the values it was handed.

Definition at line 117 of file praet_procurator.h.

◆ praet_procurator_report

#define praet_procurator_report ( )

Expands to nothing where PRAET_PROCURATOR is 0.

Definition at line 122 of file praet_procurator.h.

◆ praet_procurator_opus

#define praet_procurator_opus ( kind_)

Expands to nothing where PRAET_OPTIMIZE is 0.

Parameters
kind_What was done, discarded.

Definition at line 168 of file praet_procurator.h.