dynamic goi machine
play

Dynamic GoI machine Call-by-need and call-by-value graph rewriter - PowerPoint PPT Presentation

Dynamic GoI machine Call-by-need and call-by-value graph rewriter Koko Muroya & Dan Ghica (Univ. Birmingham) S-REPLS 4 (London), 27 September 2016 GoI machine [Danos & Regnier 99] [Mackie 95] abstract machine to interpret


  1. Dynamic GoI machine Call-by-need and call-by-value graph rewriter Koko Muroya & Dan Ghica (Univ. Birmingham) S-REPLS 4 (London), 27 September 2016

  2. GoI machine [Danos & Regnier ’99] [Mackie ’95] • abstract machine to interpret λ -calculus • a λ -term → a graph → moves of a token compositionally • Geometry of Interaction [Girard, ’89] • “an execution path on a proof net” 2 Muroya (U. Birmingham)

  3. GoI machine [Danos & Regnier ’99] [Mackie ’95] ( λ x. x ) 1 q q 1 1 Muroya (U. Birmingham)

  4. GoI machine [Danos & Regnier ’99] [Mackie ’95] ( λ x. x ) 1 q q 1 1 Muroya (U. Birmingham)

  5. GoI machine [Danos & Regnier ’99] [Mackie ’95] call-by-name • a token on a static graph • space efficiency • compositionality / interaction between components • categorical GoI [Abramsky+, ’02] • compilation to digital circuits [Ghica+, ’07-] 4 Muroya (U. Birmingham)

  6. GoI machine [Danos & Regnier ’99] [Mackie ’95] CPS transformation (Schöpp, Hoshino+) call-by-name call-by-value memory assigned to nodes (Hoshino+, Dal Lago+) • a token on a static graph parallelism: multiple tokens • space efficiency dynamic jumps (Dal Lago+) (Fernández+) 5 Muroya (U. Birmingham)

  7. Dynamic GoI machine avoid repeated evaluation call-by-name call-by-value force evaluation of • a token on a static graph function arguments • dynamic rewrites & “checkpoint” mechanism • space time efficiency • compositional reasoning • categorical GoI [Abramsky+, ’02] 6 Muroya (U. Birmingham)

  8. Avoid re-evaluation ( λ x. x + x ) (1 + 2) q q 3 q 3 6 7 Muroya (U. Birmingham)

  9. Avoid re-evaluation ( λ x. x + x ) (1 + 2) q q 3 q 3 6 7 Muroya (U. Birmingham)

  10. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 8 Muroya (U. Birmingham)

  11. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 8 Muroya (U. Birmingham)

  12. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 8 Muroya (U. Birmingham)

  13. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 9 Muroya (U. Birmingham)

  14. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 9 Muroya (U. Birmingham)

  15. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 9 Muroya (U. Birmingham)

  16. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 10 Muroya (U. Birmingham)

  17. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 10 Muroya (U. Birmingham)

  18. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 11 Muroya (U. Birmingham)

  19. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 11 Muroya (U. Birmingham)

  20. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 11 Muroya (U. Birmingham)

  21. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 12 Muroya (U. Birmingham)

  22. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 12 Muroya (U. Birmingham)

  23. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 13 Muroya (U. Birmingham)

  24. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 13 Muroya (U. Birmingham)

  25. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 14 Muroya (U. Birmingham)

  26. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 14 Muroya (U. Birmingham)

  27. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 14 Muroya (U. Birmingham)

  28. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 15 Muroya (U. Birmingham)

  29. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 15 Muroya (U. Birmingham)

  30. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 16 Muroya (U. Birmingham)

  31. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 16 Muroya (U. Birmingham)

  32. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 16 Muroya (U. Birmingham)

  33. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 17 Muroya (U. Birmingham)

  34. Avoid re-evaluation: dynamic rewrite ( λ x. x + x ) (1 + 2) 17 Muroya (U. Birmingham)

  35. Dynamic GoI machine avoid repeated evaluation call-by-name call-by-need force evaluation of • a token on a static graph function arguments • dynamic rewrites • space time efficiency • compositional reasoning • categorical GoI [Abramsky+, ’02] 18 Muroya (U. Birmingham)

  36. Force evaluation of arguments ( λ x. 0) (1 + 2) q q 3 6 19 Muroya (U. Birmingham)

  37. Force evaluation of arguments ( λ x. 0) (1 + 2) q q 3 6 19 Muroya (U. Birmingham)

  38. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 20 Muroya (U. Birmingham)

  39. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 20 Muroya (U. Birmingham)

  40. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 20 Muroya (U. Birmingham)

  41. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 21 Muroya (U. Birmingham)

  42. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 21 Muroya (U. Birmingham)

  43. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 21 Muroya (U. Birmingham)

  44. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 22 Muroya (U. Birmingham)

  45. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 22 Muroya (U. Birmingham)

  46. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 23 Muroya (U. Birmingham)

  47. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 23 Muroya (U. Birmingham)

  48. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 23 Muroya (U. Birmingham)

  49. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 24 Muroya (U. Birmingham)

  50. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 24 Muroya (U. Birmingham)

  51. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 25 Muroya (U. Birmingham)

  52. Force evaluation of arguments: checkpoint ( λ x. 0) (1 + 2) 25 Muroya (U. Birmingham)

  53. Dynamic GoI machine, extended _ (( G, ` e , ` b ) , p, d, m ) 99K (( G, ` e , ` b ) , p 0 , d 0 , m 0 ) “move” transition ( α : p, m ) ( β : Ax : α : p, m ) ( α : p, m ) ( β : Cut : α : p, m ) 99K 99K Ax Ax β β α α ↑ ↓ ↓ ↑ ( β 0 : ( ⇧ , α 0 , α ) : β : p, m ) α α β β ( β : p, m ) Cut Cut 99K ( α l : p, m ) ( β : ($ , α r ) : α l : p, l : m ) ( β : p, l : m ) ( α l : ($ , α r ) : β : p, m ) 99K 99K α 0 α α 0 α α l α r α l α r α l α r α l α r ↓ ↑ $ $ $ $ " # ↓ ↑ β β β β β 0 β β 0 β ( α r : p, m ) ( β : ($ , α l ) : α r : p, r : m ) ( β : p, r : m ) ( α r : ($ , α l ) : β : p, m ) 99K 99K α l α r α l α r α l α r α l α r ↓ ↑ $ $ $ $ ↓ ↑ ( α : p, m ) ( β : D : α : p, m ) 99K β β β β α α ( α : p, m ) ( β : ! : α : p, m ) ( β : p, m ) ( α : ! : β : p, m ) ↓ 99K 99K α α α α D D ↓ ↑ ↓ ! ! ! ! β β ↓ ↑ ( α i : p, m ) ( β : C + : α i : p, m ) ( α : p, m ) ( β : C : α : p, m ) 99K 99K β β β β α k +1 α k +1 α 1 α i α 1 α i α α ↓ · · · · · · · · · · · · ↓ C 1 C 1 C k +1 C k +1 ↓ ↓ β β β β ( β : p, m ) ( α 1 : Sum1 : β : p, m ) ( α 1 : p, m ) ( α 2 : Sum2 : α 1 : p, m ) 99K 99K α 1 α 2 α 1 α 2 α 1 α 2 α 1 α 2 ↑ ↓ ↑ Sum Sum Sum Sum ↑ β β β β ( α 2 : p, m ) ( β : Sum : α 2 : p, m ) ( α : p, m ) ( α : ( Val , n ) : α : p, m ) 99K 99K α 1 α 2 α 1 α 2 ↓ n n Sum Sum ↑ ↓ ↓ α α β β 26 Muroya (U. Birmingham)

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend