Higher-Level Paradigms for Deadlock-Free High-Performance Systems

This paper reviews the general notion of deadlock (and livelock) in parallel systems based upon synchronised message passing and relates them to the much worse problem of undetected data-loss in asynchronous or shared-memory communications. Two design paradigms (I/O-PAR and Client-Server) are presented that guarantee freedom from deadlock for synchronised communication regimes (both continuous and irregular dataow). The paradigms are based upon the notion of `synchronisation classes' for processes that are closed under certain forms of parallel composition. Checking for deadlock-freeness devolves to checking that the base processes belong to the correct classes and that the composition rules are observed. The complexity of this checking is at worst O(n), where n is the number of processes in the system, as opposed to O(sn), where s is the (average) number of states in each process. The latter would be required for an arbitrary parallel design. The automated checking of these design rules is therefore highly practical. High-performance applications (e.g. physical system modelling, embedded realtime systems, ...) generally consist of two components: the computationally intensive part (which is usually logically simple and can exploit the I/O-PAR paradigm) and its controlling apparatus (which can be highly complex but can exploit the ClientServer paradigm). This paper reports on the design rules for hybrid combinations of the two paradigms that preserve their deadlock-free properties. Examples will be presented. The classic `Dining Philsopher' system is shown to illustrate an I/O-PAR Client-Server hybrid that breaks these rules. Finally, the Client-Server paradigm will be looked at from the point of view of the special language support provided by occam3 .