Control Coupling is one of Understand's built-in reports — run it on your own code from the GUI, or headlessly with und report.
Control Coupling
Languages: AnyTargets: Project
Documents control coupling between functions: for each function, every function call it makes, classified as consumer, producer, or both.
Output mirrors Section 6.2 of the ETI / DO-178C control coupling report format. The table is filterable by Module and by function name.
Columns:
- Module – source file containing the function under analysis
- Function Under Analysis – the function making the call(s)
- Consume – called function whose return value/output is used by the function under analysis (N/A if not applicable)
- Produce – called function that the function under analysis drives/controls (N/A if not applicable)
- Decision Point – the condition/loop expression if the call appears inside a conditional or loop guard; otherwise N/A
- SVCPs – Software Verification and Certification Points, left blank for the analyst to fill in
A single call can appear as both Consume and Produce when the return value is used and the call also controls another component. Calls whose value is discarded are always Produce. Calls whose value is used are also Produce when the callee returns nothing or has visible side effects (writes to globals, statics, members, or through pointers).