a principled way of designing efficient protocols
play

A Principled Way of Designing Efficient Protocols Yoram Moses - PowerPoint PPT Presentation

A Principled Way of Designing Efficient Protocols Yoram Moses Technion Partly joint with Armando Castaeda and Yannai Gonczarowski SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 1 / 43 Motivation THEME SIROCCO is


  1. A Principled Way of Designing Efficient Protocols Yoram Moses Technion Partly joint with Armando Castañeda and Yannai Gonczarowski SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 1 / 43

  2. Motivation THEME SIROCCO is devoted to the study of the interplay between communication and knowledge in multi-processor systems from both the qualitative and quantitative viewpoints. Special emphasis is given to innovative approaches and fundamental understanding … SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 2 / 43

  3. Many Models of Distributed Computing Communication: Message passing, shared memory, visual signalling Topology: Fixed, Dynamic Timing: Clocks, timing guarantees on actions and events (synchrony asynchrony, partial synchrony) Computing power: From mainframes, servers, mobile devices, low-powered sensors Failure modes, Uniqueness of ID’s, etc... No unifying “Turing-machine” model for distributed systems Lack of general results that apply to “all systems" SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 3 / 43

  4. Computing the Max Example: Computing the Maximum ( CtM ) 1 2 3 4 75 100 80 90 Each node i has an initial value v i Agent 1 must print the maximal value After receiving “ v 2 = 100” Agent 1 has the maximum. Can she act? SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 4 / 43

  5. Computing the Max Example: Computing the Maximum ( CtM ) 1 2 3 4 75 100 80 90 v2=100 Each node i has an initial value v i Agent 1 must print the maximal value After receiving “ v 2 = 100” Agent 1 has the maximum. Can she act? SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 4 / 43

  6. Computing the Max Example: Computing the Maximum ( CtM ) 1 2 3 4 200 75 100 90 v2=100 1 2 3 4 75 100 80 90 v2=100 Each node i has an initial value v i Agent 1 must print the maximal value After receiving “ v 2 = 100” Agent 1 has the maximum. Can she act? SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 4 / 43

  7. Computing the Max Collecting Values 1 2 3 4 75 100 80 90 90 Collecting all values is not necessary Collecting all values is not sufficient: Alice might not know that she has all values SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 5 / 43

  8. Computing the Max Collecting Values 1 2 3 4 75 100 80 90 90 Collecting all values is not necessary Collecting all values is not sufficient: Alice might not know that she has all values SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 5 / 43

  9. Computing the Max Collecting Values 1 2 3 4 75 100 80 90 v2=100 100 Collecting all values is not necessary Collecting all values is not sufficient: Alice might not know that she has all values SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 5 / 43

  10. Computing the Max Collecting Values 1 2 3 4 75 100 80 90 100,80,90 Collecting all values is not necessary Collecting all values is not sufficient: Alice might not know that she has all values SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 5 / 43

  11. Computing the Max Collecting Values 1 2 3 4 5 200 80 75 100 90 100,80,90 1 2 3 4 75 100 80 90 100,80,90 Collecting all values is not necessary Collecting all values is not sufficient: Alice might not know that she has all values SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 5 / 43

  12. Computing the Max What is CtM about if not collecting values? Knowledge Knowing that Max = c is necessary and sufficient for printing c . SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 6 / 43

  13. Knowledge of Preconditions Knowing that Max = c can depend on: Messages received The agents’ protocol The domain of possible initial values The network topology Timing guarantees re: communication, synchrony, activation Possibility of failures, . . . Needing to know the maximum is an instance of a general principle SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 7 / 43

  14. Knowledge of Preconditions The Knowledge of Preconditions Principle ( K o P ) If ϕ must be true when i performs α Then K i ϕ must be true when i performs α Then is a prerequisite for SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 8 / 43

  15. Knowledge of Preconditions The Knowledge of Preconditions Principle ( K o P ) If ϕ must be true when i performs α Then K i ϕ must be true when i performs α If good credit is a prerequisite for ATM payment K atm ( credit ) Then is a prerequisite for ATM payment SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 8 / 43

  16. Knowledge of Preconditions The Knowledge of Preconditions Principle ( K o P ) If ϕ must be true when i performs α K i ϕ must be true when i performs α Then If Empty Critical Section is a prerequisite for i entering the CS K i ( empty CS ) Then is a prerequisite for i entering the CS This is useful for analyzing Mutual Exclusion [M.&Patkin 2015] SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 8 / 43

  17. Knowledge of Preconditions The Knowledge of Preconditions Principle ( K o P ) If ϕ must be true when i performs α Then K i ϕ must be true when i performs α If Alice has moved is a prerequisite for Bob’s move Then K Bob (Alice has moved) is a prerequisite for Bob’s move SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 8 / 43

  18. Knowledge of Preconditions The Knowledge of Preconditions Principle ( K o P ) If ϕ must be true when i performs α Then K i ϕ must be true when i performs α � ⇒ All standard specifications are epistemic: Knowledge is a prerequisite for action This is a fundamental theorem of multi-agent systems SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 9 / 43

  19. Modeling Knowledge in Distributed Systems A Theory of Knowledge in Distributed Systems A three decades old theory of knowledge is based on Kripke 1950’s, Hintikka [1962], Aumann [1976] Halpern and M. [1984] Parikh and Ramanujam [1985] Chandy and Misra [1986] Fagin et al. [1995], Reasoning about Knowledge SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 10 / 43

  20. Modeling Knowledge in Distributed Systems Basic notion: Indistinguishability r i r 0 i has the same state at both points SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 11 / 43

  21. Modeling Knowledge in Distributed Systems Basic notion: Indistinguishability true at an indistinguishable point ⇔ possible r 1 r 0 Max � = 100 SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 11 / 43

  22. Modeling Knowledge in Distributed Systems Basic notion: Indistinguishability X print 1 (100) r 1 r 0 Max � = 100 SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 11 / 43

  23. Modeling Knowledge in Distributed Systems Defining Knowledge in Pictures � r i i i r 0 r 00 r 000 SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 12 / 43

  24. Modeling Knowledge in Distributed Systems Defining Knowledge in Pictures � r i i i r 0 � r 00 � r 000 � SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 12 / 43

  25. Modeling Knowledge in Distributed Systems Defining Knowledge in Pictures K i � r i i i r 0 � r 00 � r 000 � SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 12 / 43

  26. Modeling Knowledge in Distributed Systems Defining Knowledge in Pictures r i i i r 0 r 00 r 000 ¬ � SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 12 / 43

  27. Modeling Knowledge in Distributed Systems Defining Knowledge in Pictures ¬ K i � r i i i r 0 r 00 r 000 ¬ � SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 12 / 43

  28. Modeling Knowledge in Distributed Systems Defining Knowledge more formally [Fagin et al. 1995] r ∶ N → G A run is a sequence of global states. A system is a set R of runs. Assumption Each global state r ( t ) determines a local state r i ( t ) for every agent i . Definition ( R , r ′ , t ′ ) ⊧ ϕ for all points ( r ′ , t ′ ) of R ( R , r , t ) ⊧ K i ϕ iff such that r i ( t ) = r ′ i ( t ′ ) . SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 13 / 43

  29. Runs and points A point ( r , t ) refers to time t in run r . Facts are "true" or "false" at a point. R × N = Pts ( R ) is the set of points in system R . (r,0) (r,1) (r,2) (r,3) (r,4) (r,t)      

  30. Modeling Knowledge in Distributed Systems A Propositional Logic of Knowledge Starting from a set Φ of primitive propositions, define L K n = L K n ( Φ ) by p ∈ Φ ∣ ¬ ϕ ∣ ϕ ∧ ϕ ∣ K 1 ϕ ∣ ⋯ ∣ K n ϕ ϕ ∶= Given an interpretation π ∶ Φ × Pts ( R ) → { True , False } ( R , r , t ) ⊧ p , for p ∈ Φ, iff π ( p , r , t ) = True . ( R , r , t ) ⊧ ¬ ϕ ( R , r , t ) / ⊧ ϕ iff ( R , r , t ) ⊧ ϕ ∧ ψ both ( R , r , t ) ⊧ ϕ and ( R , r , t ) ⊧ ψ . iff SIROCCO 2016, Helsinki ( :- ) A Useful Design Principle July 19th, 2016 15 / 43

Recommend


More recommend