Control blocks
The DC/UCF system uses three control blocks to detect deadlocked tasks:
For example, one task may be using a nonconcurrent program. When another task requests the program, the requesting task must wait for the ECB associated with the program to be posted.
These structures are used by the deadlock detector to verify that two or more tasks are in a deadlock.
Detecting Deadlocks for DC/UCF System Resources
The following figure illustrates how the system uses control blocks to detect deadlocks.
┌────────┐ ┌────────┐ Task A is using resource 1. │ DCE │ │ DCE │ │ Task A │ │ Task B │ Task B is using resource 2. └────────┘ └────────┘ -------------------------------------------------------------------------------- Task A requests resource 2. ┌────────┐ ┌────────┐ │ DCE │ │ DCE │ The system builds an ECB for │ Task A │ │ Task B │ resource 2 and a DPE linking └───┬────┘ └───┬────┘ resource 2 to task B. │ │ │ ┌───▼────┐ Task A waits for resource 2. │ │DPE B-2 │ │ └───┬────┘ │ │ │ ┌───▼────┐ │ │ ECB │ └─────────────────────►Resource│ │ 2 │ └────────┘ -------------------------------------------------------------------------------- Task B requests resource 1. ┌────────┐ ┌────────┐ │ DCE ├──┐ ┌─ ─┤ DCE │ The system builds an ECB for │ Task A │ │ │ │ Task B │ resource 1 and a DPE linking └───┬────┘ │ └───┬────┘ resource 1 to task A. │ │ │ │ │ │ │ The system checks the ECB for ┌───▼────┐ │ │ ┌───▼────┐ resource 2 and finds the DPE │DPE A-1 │ │ │DPE B-2 │ linking resource 2 to task B. └───┬────┘ │ │ └───┬────┘ │ │ │ The deadlock detector uses these │ │ │ │ structures to determine that a ┌───▼────┐ │ ┌───▼────┐ deadlock has occurred. │ ECB │ │ │ │ ECB │ │Resource│ └─────────┼───►Resource│ │ 1 ◄-- - - - - ─┘ │ 2 │ └────────┘ └────────┘
Specifying a DPE Count
The DC/UCF system allocates all DPEs at startup. The number of DPEs is specified by the DPE COUNT parameter of the system generation SYSTEM statement. You can specify an explicit value in this parameter, or you can allow the system generation compiler to calculate the value for you. The compiler calculates the number of DPEs to equal:
Note: For more information about the DPE COUNT parameter, see SYSTEM Statement.
At Runtime
At startup, the system allocates the specified number of DPEs above the 16 Mb line. When an executing CA IDMS system exhausts its primary allocation of DPEs, it creates a secondary allocation in XA storage. The size of the secondary allocation is 25% of the value defined in the SYSTEM statement.
The following considerations apply to specifying the DPE COUNT value:
|
Copyright © 2014 CA.
All rights reserved.
|
|