Automatic Synthesis of Distributed Protocols
Automatic Synthesis of Distributed Protocols
复制标题
分布式协议的自动合成
DOI:
10.1145/3061640.3061652
复制
发表时间:
2017
期刊:
影响因子:
--
通讯作者:
S. Tripakis
中科院分区:
文献类型:
--
作者:
R. Alur;S. Tripakis
Protocols for coordination among concurrent processes are an essential component of modern multiprocessor and distributed systems. The multitude of behaviors arising due to asynchronous concurrency makes the design of such protocols difficult, and consequently analyzing such protocols has been a central theme of research in formal verification for decades [25, 35, 13, 32]. Sustained research in improving verification tools has resulted in powerful heuristics for coping with the computational intractability of problems such as Boolean satisfiability and search through the state-space of concurrent systems [11, 26, 15]. Now that automated verification tools are mature enough to be applied to debugging of real-world protocols [12, 33, 23], the new research frontier is protocol synthesis for simplifying the design process via more intuitive programming abstractions for specifying the desired behavior. Traditionally a distributed protocol is modeled as a set of communicating finite-state processes. The correctness is specified by both safety and liveness requirements. In model checking, a given model of the distributed protocol is checked against its correctness requirements specified in temporal logic. In reactive synthesis, the goal is to automatically derive a protocol from the given logical requirements. The synthesis problem for reactive systems goes back to work in the 1960’s [10], with finite automata on infinite words and trees providing the crucial algorithmic apparatus, with some recent efforts to translate these results into practice [39, 30, 8] (see [18] for an excellent survey of the theory of reactive synthesis, and www.syntcomp.org for benchmarks and a competition of solvers). However, if we require the implementation to be distributed, then reactive synthesis is undecidable [40, 21]. An alternative, and potentially more feasible approach inspired by program sketching [49, 48], is to ask the programmer to specify an incomplete protocol to be completed by the synthesizer so as to satisfy all the correctness requirements. This methodology for protocol specification can be viewed as a fruitful collaboration between the designer and the synthesis tool: the programmer has to describe the structure of the desired protocol, but some details that the programmer is unsure about, for instance, regarding corner cases and handling of unexpected messages, are filled in automatically by the tool. The protocol synthesis problem then reduces to the following protocol completion problem: given a set of finite-state machines for communicating processes with incomplete transition functions, given a model of the environment, and given a set of safety and liveness requirements, find a completion of the FSMs for the processes such that the composition satisfies all the requirements. The computational complexity of this problem is Pspace, the same as that of model checking of distributed protocols. However, now we need to cope with a search with two nested exponentials: the number of possible completions of the incomplete input model is exponential and so is the number of states of the product of all the component processes for any given completion. Advances in model checking offer a way of dealing with the latter, while counterexampleguided inductive synthesis (CEGIS) is a new technology that is a potential solution for the former [49, 3, 47]. The synthesis algorithm then consists of iterative invocations of two phases: the learner chooses a candidate completion, which is then checked with respect to correctness requirements by the verifier ; violations of the requirements are supplied to the learner to prune the search space in subsequent iterations.