18.7. Data structures and algorithms for deadlock detection
We assume a subsystem that is responsible for allocating certain objects and detecting deadlock. The object types to be managed and the number of instances of each type must be specified and the subsystem must record which are allocated and which are available. A matrix of processes against allocated objects is a suitable data structure to hold the object allocation information. Let us call it an allocation matrix A where aij is the number of objects of type j allocated to process i. A request matrix B of the same structure is suitable for holding outstanding requests by processes for objects (see Figure 18.7). We require an algorithm to detect deadlock by processing these allocation ...
Get Operating Systems: Concurrent and Distributed Software Design now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.