When a thread of program execution on a computer system is executing a
critical code section, i.e., a code section whose preemption could result
in inconsistency, it asserts an indicator of that fact. When the system's
scheduler reschedules the thread for execution, it determines whether the
indicator is asserted. If the indicator is asserted, the scheduler does
not cause the thread immediately to resume execution where the thread
left off when it was preempted. Instead, the scheduler has the thread's
signal handler execute in such a manner that the thread performs
inconsistency-avoiding operations.