liveBook · Manning

Safety-critical application

As explained in Memory Safe C++

A system whose failure could cause serious harm, including harm propagated through connected systems.

A safety-critical application is one whose failure could cause serious harm, including death, injury, equipment destruction, environmental damage, or harm cascading into connected systems. Its software must be supported by evidence that physical harm will not occur before it ships. section 1.1

Radiotherapy overdose

A radiotherapy machine must calculate the correct dose and position its beam accurately. In the Therac-25 incidents, patients received doses hundreds of times higher than intended, causing deaths and severe injuries. section 1.1

Criticality can apply to components as well as whole systems. A vehicle may run critical and non-critical software on the same hardware; its safety argument must show that the latter cannot interfere with the former. Failures can also emerge from interactions with noisy sensors, shared memory, or resources exhausted by a slow memory leak. section 1.1

Memory errors illustrate why consequences depend on context. The CrowdStrike outage involved an out-of-bounds read and disrupted hospitals, airlines, and emergency services, although the software was not itself safety-critical. An equivalent error in an infusion pump or flight control computer could have physical consequences. section 1.0

Not every safety-critical application is real-time, and not every real-time application is safety-critical. Chemotherapy dosing requires correct results but allows human review; a delayed video call degrades service without causing the same kind of harm. Where both constraints apply, results must be correct and arrive within verifiable time bounds. A hard real-time deadline counts as a failure if missed, regardless of how long the deadline is. section 1.2

Figure 1.2 Mapping systems by real-time and safety-critical constraints. Systems in the top-right quadrant face both simultaneously: they must be correct and meet strict timing guarantees. Chemotherapy dosing and aircraft load-and-balance calculation are safety-critical but not real-time; a person checks the numbers before anyone acts on them, so timing is not a safety concern. Video streaming is real-time but not safety-critical; a buffer underrun is frustrating, not fatal.

Compare applications by safety-critical and real-time constraints. section 1.2

How Memory Safe C++ covers it

How deep it goes
Defines criticality at system and component levels, then explains interaction failures and the distinction between safety and timing constraints.
Examples
Uses the Therac-25 overdoses, the CrowdStrike outage, chemotherapy dosing, and flight control to illustrate consequences and timing differences.
What you can do after
Evaluate whether an application is safety-critical, real-time, or both, and recognize why component interactions matter.
How it connects
Connects safety-critical software with memory safety, reliability, real-time systems, and hard real-time deadlines.

Also explained in

Compare how 2 books explain safety-critical application →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Memory Safe C++. The section links point to the parts of the book it draws on.