gtpc3m0q | Concepts and Structures |
Two types of control diagrams are used to show the structural characteristics of the TPF system:
The main distinction between these types of diagrams is that a control structure diagram does not have arrows, while a control transfer diagram does.
Figure 14 is a control structure diagram. A node in a control diagram is interpreted in the following sense:
Figure 14. Simple System Control Structure Diagram
The control program in the TPF system manages the time dependencies caused by sharing resources among concurrent and simultaneous processes. Concurrent processes can be explained as when the first operation of one process is started before the last operation of another process is completed. Simultaneous processes are defined as when the operation of several processes can occur during the same moments of time. Notice that simultaneous processes are concurrent processes, but the opposite is not necessarily true.
A control structure diagram emphasizes the structure within a single I-stream engine. Within a central processing complex (CPC), such a control structure is associated with each I-stream engine. Each of the processes (nodes) has the potential for invoking a TPF processor lock on a resource which, if accessed by another I-stream engine, generally delays further progress on the other I-stream engine. However, simply invoking a TPF processor lock does not mean that all other I-stream engines are delayed. Simultaneous access to the same resource is required to cause an I-stream engine delay. Delays because of processor locking are minimal.
The lines connecting the nodes (processes) do not necessarily represent simple transfer instructions. They are used to show that the connected elements must occasionally invoke locking mechanisms in order to do their processing; otherwise, the TPF system becomes confused. Invoking a processor lock always creates the potential for an I-stream engine control diagram to become connected to any other I-stream engine control diagram; for example, when two I-stream engines attempt to lock at exactly the same instance of time. Within the context of control diagrams, the interrupt mask bits in a PSW also represent a lock; this locking is done to synchronize processing between an I-stream engine and the engines within a channel subsystem.
Consider the following hypothetical situation that occurs in the simple system shown in Figure 14. When an application requests a system service that results in a supervisor call (SVC) instruction to perform disk I/O (input/output), the application expects control back when the I/O is started, placed on a queue of work to be performed, or completed.
During the interval that the SVC instruction is being interpreted by the I-stream engine, an interrupt-causing signal occurs as a result of random input from the communications facilities. Also, a timer causes an external interrupt to occur. The hardware interrupt mechanism stacks the interrupts (as described under "Interrupt Processing"). The SVC service routine allows each of these interrupts to be processed in turn and ultimately builds the channel commands for initiating the I/O. Some of the service processing can be done with more interrupts permitted. However, there are intervals of time, such as when the common I/O routines are invoked, when further I/O must be inhibited; otherwise, status information could be lost. This is done with a set system mask (SSM) instruction.
Finally, the control program service routine loads the old SVC PSW, which passes control directly back to the application program that requested the system service.
Now look at this activity and its relationship to the control structure diagram. Although the control program service routine transfers directly to the application program, this is only possible because:
All these things happen at different points in the processing but enable the TPF system to finally return control to the application from the service routine. The indicators in the hardware are maintained in a manner such that:
So even though the transfers can be as given in Figure 15, the control structure should be viewed as given in Figure 14. For this reason the lines in the control structure diagram do not have arrows, which is meant to emphasize that they are not necessarily transfer instructions but represent queues or status.
The nodes in a control diagram represent sequential processes.