summaryrefslogtreecommitdiff
path: root/chapter06/docs
diff options
context:
space:
mode:
authorCliff Click <cliffc@acm.org>2026-10-02 13:04:34 -0700
committerCliff Click <cliffc@acm.org>2026-10-02 13:04:34 -0700
commite4dc3273f201ae741637b626998637cce973546b (patch)
tree7607c1da4378da42549e8142371d95bdca4e06e0 /chapter06/docs
parent6cd01a8d646750748a0af221073de8a7787472ad (diff)
downloadSimple-e4dc3273f201ae741637b626998637cce973546b.tar.gz
Simple-e4dc3273f201ae741637b626998637cce973546b.zip
First pass README updates
Diffstat (limited to 'chapter06/docs')
-rw-r--r--chapter06/docs/06-graph1-post.json16
-rw-r--r--chapter06/docs/06-graph1-post.svg147
-rw-r--r--chapter06/docs/06-graph1-pre.json24
-rw-r--r--chapter06/docs/06-graph1-pre.svg271
-rw-r--r--chapter06/docs/06-graph2-post.json16
-rw-r--r--chapter06/docs/06-graph2-post.svg147
-rw-r--r--chapter06/docs/06-graph2-pre.json24
-rw-r--r--chapter06/docs/06-graph2-pre.svg262
-rw-r--r--chapter06/docs/06-graph3-nonconst-peephole.json24
-rw-r--r--chapter06/docs/06-graph3-nonconst-peephole.svg259
-rw-r--r--chapter06/docs/06-graph3-nonconst.json35
-rw-r--r--chapter06/docs/06-graph3-nonconst.svg440
-rw-r--r--chapter06/docs/Makefile13
13 files changed, 778 insertions, 900 deletions
diff --git a/chapter06/docs/06-graph1-post.json b/chapter06/docs/06-graph1-post.json
new file mode 100644
index 00000000..325d473a
--- /dev/null
+++ b/chapter06/docs/06-graph1-post.json
@@ -0,0 +1,16 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph1-post.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 13, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 12, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 13, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 12, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ ]
+}
diff --git a/chapter06/docs/06-graph1-post.svg b/chapter06/docs/06-graph1-post.svg
index faabcd8c..faef1501 100644
--- a/chapter06/docs/06-graph1-post.svg
+++ b/chapter06/docs/06-graph1-post.svg
@@ -1,67 +1,80 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="178pt" height="248pt"
- viewBox="0.00 0.00 178.00 248.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 244)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-244 174,-244 174,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-232 162,-232 162,-8 8,-8"/>
-</g>
-<!-- Start2 -->
-<g id="node1" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="24,-195 24,-220 74,-220 74,-195 24,-195"/>
-<polygon fill="none" stroke="black" points="24,-195 24,-220 74,-220 74,-195 24,-195"/>
-<text text-anchor="start" x="30.5" y="-203.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="24,-164 24,-195 74,-195 74,-164 24,-164"/>
-<polygon fill="yellow" stroke="transparent" points="29,-169 29,-190 69,-190 69,-169 29,-169"/>
-<polygon fill="none" stroke="black" points="29,-169 29,-190 69,-190 69,-169 29,-169"/>
-<text text-anchor="start" x="32" y="-175.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-</g>
-<!-- Stop3 -->
-<g id="node2" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="112,-52 58,-52 58,-16 112,-16 112,-52"/>
-<text text-anchor="middle" x="85" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Return13 -->
-<g id="node4" class="node">
-<title>Return13</title>
-<polygon fill="yellow" stroke="black" points="118,-124 52,-124 52,-88 118,-88 118,-124"/>
-<text text-anchor="middle" x="85" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Stop3&#45;&gt;Return13 -->
-<g id="edge1" class="edge">
-<title>Stop3&#45;&gt;Return13</title>
-<path fill="none" stroke="red" d="M85,-52.3C85,-60.02 85,-69.29 85,-77.89"/>
-<polygon fill="red" stroke="red" points="81.5,-77.9 85,-87.9 88.5,-77.9 81.5,-77.9"/>
-<text text-anchor="middle" x="82" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Con_12 -->
-<g id="node3" class="node">
-<title>Con_12</title>
-<ellipse fill="none" stroke="black" cx="127" cy="-192" rx="27" ry="18"/>
-<text text-anchor="middle" x="127" y="-188.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- Return13&#45;&gt;Start2 -->
-<g id="edge2" class="edge">
-<title>Return13&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M68.26,-124.13C60.77,-133.26 52.99,-145.23 50.13,-158.06"/>
-<polygon fill="red" stroke="red" points="46.66,-157.67 49,-168 53.61,-158.46 46.66,-157.67"/>
-<text text-anchor="middle" x="65.26" y="-126.73" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return13&#45;&gt;Con_12 -->
-<g id="edge3" class="edge">
-<title>Return13&#45;&gt;Con_12</title>
-<path fill="none" stroke="black" d="M93.7,-124.4C99.66,-136.31 107.65,-152.3 114.31,-165.62"/>
-<polygon fill="black" stroke="black" points="111.28,-167.38 118.88,-174.76 117.54,-164.25 111.28,-167.38"/>
-<text text-anchor="middle" x="90.7" y="-127" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="326" height="320" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 326 320" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"/><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M104,219 C104,243 163,246 163,270" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #13 · CTRL</title></path><path class="edge CTRL" id="e13i0" d="M84,118 L84,166" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#13[0] → #1 · CTRL</title></path><path class="edge DATA" id="e13i1" d="M242,118 L242,128 L124,128 L124,166" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#13[1] → #12 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(24,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(24,24)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(127,270)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #13 CTRL</title><circle class="port" cx="36" cy="0" r="3" fill="#536477"/><text class="slot" x="36" y="-7" text-anchor="middle">0</text></g><g class="node" id="n12" data-id="12" transform="translate(182,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #12</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#12 #2
+Type not computed
+
+</title></g><g class="node" id="n13" data-id="13" transform="translate(44,172)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #13</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#13 Return
+Type not computed
+
+[0] → #1 CTRL
+[1] → #12 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"/><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/06-graph1-pre.json b/chapter06/docs/06-graph1-pre.json
new file mode 100644
index 00000000..18615f2c
--- /dev/null
+++ b/chapter06/docs/06-graph1-pre.json
@@ -0,0 +1,24 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph1-pre.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 12, "role": "CTRL", "label": null}, {"idx": 1, "def": 16, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 4, "label": "True", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 7, "role": "CTRL", "label": null}], "proj": {"par": 7, "idx": 0}},
+ {"id": 5, "label": "False", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 7, "role": "CTRL", "label": null}], "proj": {"par": 7, "idx": 1}},
+ {"id": 6, "label": "#1", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 7, "label": "If", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 6, "role": "DATA", "label": null}], "proj": null},
+ {"id": 11, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 12, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 4, "role": "CTRL", "label": null}, {"idx": 1, "def": 11, "role": "DATA", "label": null}], "proj": null},
+ {"id": 13, "label": "#~CONTROL", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 14, "label": "Region", "type": null, "kind": "REGION", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 13, "role": "DATA", "label": null}, {"idx": 2, "def": 5, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 15, "label": "#1", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 16, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 14, "role": "CTRL", "label": null}, {"idx": 1, "def": 15, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ ]
+}
diff --git a/chapter06/docs/06-graph1-pre.svg b/chapter06/docs/06-graph1-pre.svg
index f80edcfc..2ba929f8 100644
--- a/chapter06/docs/06-graph1-pre.svg
+++ b/chapter06/docs/06-graph1-pre.svg
@@ -1,160 +1,111 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="316pt" height="420pt"
- viewBox="0.00 0.00 316.00 420.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 416)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-416 312,-416 312,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-404 300,-404 300,-8 8,-8"/>
-</g>
-<!-- Start2 -->
-<g id="node1" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="35,-367 35,-392 85,-392 85,-367 35,-367"/>
-<polygon fill="none" stroke="black" points="35,-367 35,-392 85,-392 85,-367 35,-367"/>
-<text text-anchor="start" x="41.5" y="-375.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="35,-336 35,-367 85,-367 85,-336 35,-336"/>
-<polygon fill="yellow" stroke="transparent" points="40,-341 40,-362 80,-362 80,-341 40,-341"/>
-<polygon fill="none" stroke="black" points="40,-341 40,-362 80,-362 80,-341 40,-341"/>
-<text text-anchor="start" x="43" y="-347.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-</g>
-<!-- Stop3 -->
-<g id="node2" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="150,-52 96,-52 96,-16 150,-16 150,-52"/>
-<text text-anchor="middle" x="123" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Return12 -->
-<g id="node6" class="node">
-<title>Return12</title>
-<polygon fill="yellow" stroke="black" points="114,-124 48,-124 48,-88 114,-88 114,-124"/>
-<text text-anchor="middle" x="81" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Stop3&#45;&gt;Return12 -->
-<g id="edge1" class="edge">
-<title>Stop3&#45;&gt;Return12</title>
-<path fill="none" stroke="red" d="M112.62,-52.3C107.74,-60.44 101.81,-70.31 96.42,-79.3"/>
-<polygon fill="red" stroke="red" points="93.41,-77.52 91.26,-87.9 99.41,-81.12 93.41,-77.52"/>
-<text text-anchor="middle" x="109.62" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return16 -->
-<g id="node10" class="node">
-<title>Return16</title>
-<polygon fill="yellow" stroke="black" points="198,-124 132,-124 132,-88 198,-88 198,-124"/>
-<text text-anchor="middle" x="165" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Stop3&#45;&gt;Return16 -->
-<g id="edge2" class="edge">
-<title>Stop3&#45;&gt;Return16</title>
-<path fill="none" stroke="red" d="M133.38,-52.3C138.26,-60.44 144.19,-70.31 149.58,-79.3"/>
-<polygon fill="red" stroke="red" points="146.59,-81.12 154.74,-87.9 152.59,-77.52 146.59,-81.12"/>
-<text text-anchor="middle" x="130.38" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_6 -->
-<g id="node3" class="node">
-<title>Con_6</title>
-<ellipse fill="none" stroke="black" cx="138" cy="-364" rx="27" ry="18"/>
-<text text-anchor="middle" x="138" y="-360.3" font-family="Times,serif" font-size="14.00">#1</text>
-</g>
-<!-- If7 -->
-<g id="node4" class="node">
-<title>If7</title>
-<polygon fill="yellow" stroke="transparent" points="24,-267 24,-292 118,-292 118,-267 24,-267"/>
-<polygon fill="none" stroke="black" points="24,-267 24,-292 118,-292 118,-267 24,-267"/>
-<text text-anchor="start" x="65.5" y="-275.8" font-family="Times,serif" font-size="14.00">If</text>
-<polygon fill="none" stroke="black" points="24,-236 24,-267 118,-267 118,-236 24,-236"/>
-<polygon fill="yellow" stroke="transparent" points="29,-241 29,-262 69,-262 69,-241 29,-241"/>
-<polygon fill="none" stroke="black" points="29,-241 29,-262 69,-262 69,-241 29,-241"/>
-<text text-anchor="start" x="32" y="-247.8" font-family="Times,serif" font-size="14.00">True</text>
-<polygon fill="yellow" stroke="transparent" points="69,-241 69,-262 113,-262 113,-241 69,-241"/>
-<polygon fill="none" stroke="black" points="69,-241 69,-262 113,-262 113,-241 69,-241"/>
-<text text-anchor="start" x="72" y="-247.8" font-family="Times,serif" font-size="14.00">False</text>
-</g>
-<!-- If7&#45;&gt;Start2 -->
-<g id="edge3" class="edge">
-<title>If7&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M64.35,-296.23C62.56,-306.6 60.93,-318.45 60.29,-329.99"/>
-<polygon fill="red" stroke="red" points="56.79,-329.9 60,-340 63.79,-330.11 56.79,-329.9"/>
-<text text-anchor="middle" x="61.35" y="-298.83" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- If7&#45;&gt;Con_6 -->
-<g id="edge4" class="edge">
-<title>If7&#45;&gt;Con_6</title>
-<path fill="none" stroke="black" d="M92.2,-296.01C101.67,-309.86 112.66,-325.94 121.5,-338.87"/>
-<polygon fill="black" stroke="black" points="118.7,-340.97 127.24,-347.25 124.48,-337.02 118.7,-340.97"/>
-<text text-anchor="middle" x="89.2" y="-298.61" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_11 -->
-<g id="node5" class="node">
-<title>Con_11</title>
-<ellipse fill="none" stroke="black" cx="43" cy="-178" rx="27" ry="18"/>
-<text text-anchor="middle" x="43" y="-174.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- Return12&#45;&gt;If7 -->
-<g id="edge5" class="edge">
-<title>Return12&#45;&gt;If7:p0</title>
-<path fill="none" stroke="red" d="M83.45,-124.21C85.4,-142.49 86.7,-172.01 79,-196 73.01,-214.66 56.37,-216.36 50.82,-229.83"/>
-<polygon fill="red" stroke="red" points="47.32,-229.54 49,-240 54.21,-230.77 47.32,-229.54"/>
-<text text-anchor="middle" x="80.45" y="-126.81" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return12&#45;&gt;Con_11 -->
-<g id="edge6" class="edge">
-<title>Return12&#45;&gt;Con_11</title>
-<path fill="none" stroke="black" d="M71.61,-124.3C67.1,-132.6 61.63,-142.69 56.67,-151.81"/>
-<polygon fill="black" stroke="black" points="53.46,-150.4 51.76,-160.86 59.61,-153.74 53.46,-150.4"/>
-<text text-anchor="middle" x="68.61" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_13 -->
-<g id="node7" class="node">
-<title>Con_13</title>
-<ellipse fill="none" stroke="black" cx="218" cy="-264" rx="74.19" ry="18"/>
-<text text-anchor="middle" x="218" y="-260.3" font-family="Times,serif" font-size="14.00">#~CONTROL</text>
-</g>
-<!-- Region14 -->
-<g id="node8" class="node">
-<title>Region14</title>
-<polygon fill="yellow" stroke="black" points="190,-196 124,-196 124,-160 190,-160 190,-196"/>
-<text text-anchor="middle" x="157" y="-174.3" font-family="Times,serif" font-size="14.00">Region</text>
-</g>
-<!-- Region14&#45;&gt;If7 -->
-<g id="edge8" class="edge">
-<title>Region14&#45;&gt;If7:p1</title>
-<path fill="none" stroke="red" d="M150.64,-196.06C144.08,-212.53 133.37,-236.39 122.96,-246.35"/>
-<polygon fill="red" stroke="red" points="121.27,-243.29 114,-251 124.49,-249.5 121.27,-243.29"/>
-<text text-anchor="middle" x="147.64" y="-198.66" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Region14&#45;&gt;Con_13 -->
-<g id="edge7" class="edge">
-<title>Region14&#45;&gt;Con_13</title>
-<path fill="none" stroke="black" d="M169.64,-196.4C178.34,-208.39 190.04,-224.5 199.75,-237.87"/>
-<polygon fill="black" stroke="black" points="197.09,-240.16 205.79,-246.19 202.75,-236.04 197.09,-240.16"/>
-<text text-anchor="middle" x="166.64" y="-199" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_15 -->
-<g id="node9" class="node">
-<title>Con_15</title>
-<ellipse fill="none" stroke="black" cx="235" cy="-178" rx="27" ry="18"/>
-<text text-anchor="middle" x="235" y="-174.3" font-family="Times,serif" font-size="14.00">#1</text>
-</g>
-<!-- Return16&#45;&gt;Region14 -->
-<g id="edge9" class="edge">
-<title>Return16&#45;&gt;Region14</title>
-<path fill="none" stroke="red" d="M163.02,-124.3C162.14,-132.02 161.08,-141.29 160.1,-149.89"/>
-<polygon fill="red" stroke="red" points="156.61,-149.56 158.95,-159.9 163.57,-150.36 156.61,-149.56"/>
-<text text-anchor="middle" x="160.02" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return16&#45;&gt;Con_15 -->
-<g id="edge10" class="edge">
-<title>Return16&#45;&gt;Con_15</title>
-<path fill="none" stroke="black" d="M182.3,-124.3C191.72,-133.72 203.47,-145.47 213.47,-155.47"/>
-<polygon fill="black" stroke="black" points="211.18,-158.12 220.72,-162.72 216.12,-153.18 211.18,-158.12"/>
-<text text-anchor="middle" x="179.3" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="598" height="572" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 598 572" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"/><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M256,367 C256,391 287,498 287,522" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #12 · CTRL</title></path><path class="edge CTRL" id="e3i1" d="M124,471 C124,495 311,498 311,522" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[1] → #16 · CTRL</title></path><path class="edge CTRL" id="e7i0" d="M256,118 L256,166" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#7[0] → #1 · CTRL</title></path><path class="edge DATA" id="e7i1" d="M414,118 L414,128 L336,128 L336,166" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#7[1] → #6 · DATA</title></path><path class="edge CTRL" id="e12i0" d="M236,266 L236,314" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#12[0] → #4 · CTRL</title></path><path class="edge DATA" id="e12i1" d="M514,266 L514,286 L276,286 L276,314" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#12[1] → #11 · DATA</title></path><path class="edge DATA" id="e14i1" d="M84,266 L84,276 L104,276 L104,314" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#14[1] → #13 · DATA</title></path><path class="edge CTRL" id="e14i2" d="M356,266 L356,276 L134,276 L134,314" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#14[2] → #5 · CTRL</title></path><path class="edge CTRL" id="e16i0" d="M104,370 L104,418" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#16[0] → #14 · CTRL</title></path><path class="edge DATA" id="e16i1" d="M408,370 L408,380 L144,380 L144,418" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#16[1] → #15 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(196,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(196,24)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(263,522)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #12 CTRL
+[1] → #16 CTRL</title><circle class="port" cx="24" cy="0" r="3" fill="#536477"/><circle class="port" cx="48" cy="0" r="3" fill="#536477"/><text class="slot" x="24" y="-7" text-anchor="middle">0</text><text class="slot" x="48" y="-7" text-anchor="middle">1</text></g><g class="node" id="n4" data-id="4" transform="translate(176,216)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>True</tspan><tspan class="node-id">  #4/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#4 True
+Projection 0 of #7
+Type not computed
+
+[0] → #7 CTRL</title></g><g class="node" id="n5" data-id="5" transform="translate(296,216)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>False</tspan><tspan class="node-id">  #5/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#5 False
+Projection 1 of #7
+Type not computed
+
+[0] → #7 CTRL</title></g><g class="node" id="n6" data-id="6" transform="translate(354,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#1</tspan><tspan class="node-id">  #6</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#6 #1
+Type not computed
+
+</title></g><g class="node" id="n7" data-id="7" transform="translate(176,172)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>If</tspan><tspan class="node-id">  #7</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#7 If
+Type not computed
+
+[0] → #1 CTRL
+[1] → #6 DATA</title><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><circle class="port" cx="160" cy="-3" r="3" fill="#536477"/><text class="slot" x="80" y="-10" text-anchor="middle">0</text><text class="slot" x="160" y="-10" text-anchor="middle">1</text></g><g class="node" id="n11" data-id="11" transform="translate(454,216)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #11</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#11 #2
+Type not computed
+
+</title></g><g class="node" id="n12" data-id="12" transform="translate(196,320)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #12</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#12 Return
+Type not computed
+
+[0] → #4 CTRL
+[1] → #11 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g><g class="node" id="n13" data-id="13" transform="translate(24,216)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#~CONTROL</tspan><tspan class="node-id">  #13</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#13 #~CONTROL
+Type not computed
+
+</title></g><g class="node" id="n14" data-id="14" transform="translate(44,320)" style="opacity: 1;"><path class="box" d="M12,0H108L120,44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Region</tspan><tspan class="node-id">  #14</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#14 Region
+Type not computed
+
+[0] → — DATA
+[1] → #13 DATA
+[2] → #5 CTRL</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n15" data-id="15" transform="translate(348,320)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#1</tspan><tspan class="node-id">  #15</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#15 #1
+Type not computed
+
+</title></g><g class="node" id="n16" data-id="16" transform="translate(64,424)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #16</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#16 Return
+Type not computed
+
+[0] → #14 CTRL
+[1] → #15 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"/><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/06-graph2-post.json b/chapter06/docs/06-graph2-post.json
new file mode 100644
index 00000000..31be64c2
--- /dev/null
+++ b/chapter06/docs/06-graph2-post.json
@@ -0,0 +1,16 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph2-post.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 17, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 13, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 17, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 13, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ ]
+}
diff --git a/chapter06/docs/06-graph2-post.svg b/chapter06/docs/06-graph2-post.svg
index 269eb15c..db95f198 100644
--- a/chapter06/docs/06-graph2-post.svg
+++ b/chapter06/docs/06-graph2-post.svg
@@ -1,67 +1,80 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="178pt" height="248pt"
- viewBox="0.00 0.00 178.00 248.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 244)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-244 174,-244 174,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-232 162,-232 162,-8 8,-8"/>
-</g>
-<!-- Return17 -->
-<g id="node1" class="node">
-<title>Return17</title>
-<polygon fill="yellow" stroke="black" points="118,-124 52,-124 52,-88 118,-88 118,-124"/>
-<text text-anchor="middle" x="85" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Start2 -->
-<g id="node2" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="24,-195 24,-220 74,-220 74,-195 24,-195"/>
-<polygon fill="none" stroke="black" points="24,-195 24,-220 74,-220 74,-195 24,-195"/>
-<text text-anchor="start" x="30.5" y="-203.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="24,-164 24,-195 74,-195 74,-164 24,-164"/>
-<polygon fill="yellow" stroke="transparent" points="29,-169 29,-190 69,-190 69,-169 29,-169"/>
-<polygon fill="none" stroke="black" points="29,-169 29,-190 69,-190 69,-169 29,-169"/>
-<text text-anchor="start" x="32" y="-175.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-</g>
-<!-- Return17&#45;&gt;Start2 -->
-<g id="edge1" class="edge">
-<title>Return17&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M68.26,-124.13C60.77,-133.26 52.99,-145.23 50.13,-158.06"/>
-<polygon fill="red" stroke="red" points="46.66,-157.67 49,-168 53.61,-158.46 46.66,-157.67"/>
-<text text-anchor="middle" x="65.26" y="-126.73" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Con_13 -->
-<g id="node4" class="node">
-<title>Con_13</title>
-<ellipse fill="none" stroke="black" cx="127" cy="-192" rx="27" ry="18"/>
-<text text-anchor="middle" x="127" y="-188.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- Return17&#45;&gt;Con_13 -->
-<g id="edge2" class="edge">
-<title>Return17&#45;&gt;Con_13</title>
-<path fill="none" stroke="black" d="M93.7,-124.4C99.66,-136.31 107.65,-152.3 114.31,-165.62"/>
-<polygon fill="black" stroke="black" points="111.28,-167.38 118.88,-174.76 117.54,-164.25 111.28,-167.38"/>
-<text text-anchor="middle" x="90.7" y="-127" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Stop3 -->
-<g id="node3" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="112,-52 58,-52 58,-16 112,-16 112,-52"/>
-<text text-anchor="middle" x="85" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Stop3&#45;&gt;Return17 -->
-<g id="edge3" class="edge">
-<title>Stop3&#45;&gt;Return17</title>
-<path fill="none" stroke="red" d="M85,-52.3C85,-60.02 85,-69.29 85,-77.89"/>
-<polygon fill="red" stroke="red" points="81.5,-77.9 85,-87.9 88.5,-77.9 81.5,-77.9"/>
-<text text-anchor="middle" x="82" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="326" height="320" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 326 320" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"/><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M104,219 C104,243 163,246 163,270" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #17 · CTRL</title></path><path class="edge CTRL" id="e17i0" d="M84,118 L84,166" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#17[0] → #1 · CTRL</title></path><path class="edge DATA" id="e17i1" d="M242,118 L242,128 L124,128 L124,166" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#17[1] → #13 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(24,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(24,24)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(127,270)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #17 CTRL</title><circle class="port" cx="36" cy="0" r="3" fill="#536477"/><text class="slot" x="36" y="-7" text-anchor="middle">0</text></g><g class="node" id="n13" data-id="13" transform="translate(182,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #13</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#13 #2
+Type not computed
+
+</title></g><g class="node" id="n17" data-id="17" transform="translate(44,172)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #17</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#17 Return
+Type not computed
+
+[0] → #1 CTRL
+[1] → #13 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"/><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/06-graph2-pre.json b/chapter06/docs/06-graph2-pre.json
new file mode 100644
index 00000000..fd187946
--- /dev/null
+++ b/chapter06/docs/06-graph2-pre.json
@@ -0,0 +1,24 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph2-pre.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 16, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 4, "label": "True", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 0}},
+ {"id": 5, "label": "False", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 1}},
+ {"id": 7, "label": "#1", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 8, "label": "If", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 7, "role": "DATA", "label": null}], "proj": null},
+ {"id": 12, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 13, "label": "#3", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 14, "label": "Region", "type": null, "kind": "REGION", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 4, "role": "CTRL", "label": null}, {"idx": 2, "def": 5, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 15, "label": "φ_a", "type": null, "kind": "PHI", "edges": [{"idx": 0, "def": 14, "role": "ASSOC", "label": null}, {"idx": 1, "def": 12, "role": "DATA", "label": null}, {"idx": 2, "def": 13, "role": "DATA", "label": null}], "proj": null},
+ {"id": 16, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 14, "role": "CTRL", "label": null}, {"idx": 1, "def": 15, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ {"id": 8, "par": 0, "nodes": [4, 5, 8, 14, 15]}
+ ]
+}
diff --git a/chapter06/docs/06-graph2-pre.svg b/chapter06/docs/06-graph2-pre.svg
index e9a4dd55..bbc372f3 100644
--- a/chapter06/docs/06-graph2-pre.svg
+++ b/chapter06/docs/06-graph2-pre.svg
@@ -1,154 +1,108 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="294pt" height="420pt"
- viewBox="0.00 0.00 294.00 420.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 416)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-416 290,-416 290,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-404 278,-404 278,-8 8,-8"/>
-</g>
-<!-- Return16 -->
-<g id="node1" class="node">
-<title>Return16</title>
-<polygon fill="yellow" stroke="black" points="187,-124 121,-124 121,-88 187,-88 187,-124"/>
-<text text-anchor="middle" x="154" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Region14 -->
-<g id="node8" class="node">
-<title>Region14</title>
-<polygon fill="yellow" stroke="black" points="226,-196 160,-196 160,-160 226,-160 226,-196"/>
-<text text-anchor="middle" x="193" y="-174.3" font-family="Times,serif" font-size="14.00">Region</text>
-</g>
-<!-- Return16&#45;&gt;Region14 -->
-<g id="edge1" class="edge">
-<title>Return16&#45;&gt;Region14</title>
-<path fill="none" stroke="red" d="M163.64,-124.3C168.13,-132.36 173.56,-142.11 178.52,-151.02"/>
-<polygon fill="red" stroke="red" points="175.55,-152.86 183.47,-159.9 181.66,-149.46 175.55,-152.86"/>
-<text text-anchor="middle" x="160.64" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Phi_a15 -->
-<g id="node9" class="node">
-<title>Phi_a15</title>
-<ellipse fill="lightyellow" stroke="black" cx="115" cy="-178" rx="27" ry="18"/>
-<text text-anchor="middle" x="115" y="-174.3" font-family="Times,serif" font-size="14.00">φ_a</text>
-</g>
-<!-- Return16&#45;&gt;Phi_a15 -->
-<g id="edge2" class="edge">
-<title>Return16&#45;&gt;Phi_a15</title>
-<path fill="none" stroke="black" d="M144.36,-124.3C139.69,-132.68 134,-142.9 128.87,-152.1"/>
-<polygon fill="black" stroke="black" points="125.8,-150.42 123.99,-160.86 131.92,-153.82 125.8,-150.42"/>
-<text text-anchor="middle" x="141.36" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Start2 -->
-<g id="node2" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="126,-367 126,-392 176,-392 176,-367 126,-367"/>
-<polygon fill="none" stroke="black" points="126,-367 126,-392 176,-392 176,-367 126,-367"/>
-<text text-anchor="start" x="132.5" y="-375.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="126,-336 126,-367 176,-367 176,-336 126,-336"/>
-<polygon fill="yellow" stroke="transparent" points="131,-341 131,-362 171,-362 171,-341 131,-341"/>
-<polygon fill="none" stroke="black" points="131,-341 131,-362 171,-362 171,-341 131,-341"/>
-<text text-anchor="start" x="134" y="-347.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-</g>
-<!-- Stop3 -->
-<g id="node3" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="181,-52 127,-52 127,-16 181,-16 181,-52"/>
-<text text-anchor="middle" x="154" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Stop3&#45;&gt;Return16 -->
-<g id="edge3" class="edge">
-<title>Stop3&#45;&gt;Return16</title>
-<path fill="none" stroke="red" d="M154,-52.3C154,-60.02 154,-69.29 154,-77.89"/>
-<polygon fill="red" stroke="red" points="150.5,-77.9 154,-87.9 157.5,-77.9 150.5,-77.9"/>
-<text text-anchor="middle" x="151" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Con_7 -->
-<g id="node4" class="node">
-<title>Con_7</title>
-<ellipse fill="none" stroke="black" cx="229" cy="-364" rx="27" ry="18"/>
-<text text-anchor="middle" x="229" y="-360.3" font-family="Times,serif" font-size="14.00">#1</text>
-</g>
-<!-- If8 -->
-<g id="node5" class="node">
-<title>If8</title>
-<polygon fill="yellow" stroke="transparent" points="168,-267 168,-292 262,-292 262,-267 168,-267"/>
-<polygon fill="none" stroke="black" points="168,-267 168,-292 262,-292 262,-267 168,-267"/>
-<text text-anchor="start" x="209.5" y="-275.8" font-family="Times,serif" font-size="14.00">If</text>
-<polygon fill="none" stroke="black" points="168,-236 168,-267 262,-267 262,-236 168,-236"/>
-<polygon fill="yellow" stroke="transparent" points="173,-241 173,-262 213,-262 213,-241 173,-241"/>
-<polygon fill="none" stroke="black" points="173,-241 173,-262 213,-262 213,-241 173,-241"/>
-<text text-anchor="start" x="176" y="-247.8" font-family="Times,serif" font-size="14.00">True</text>
-<polygon fill="yellow" stroke="transparent" points="213,-241 213,-262 257,-262 257,-241 213,-241"/>
-<polygon fill="none" stroke="black" points="213,-241 213,-262 257,-262 257,-241 213,-241"/>
-<text text-anchor="start" x="216" y="-247.8" font-family="Times,serif" font-size="14.00">False</text>
-</g>
-<!-- If8&#45;&gt;Start2 -->
-<g id="edge4" class="edge">
-<title>If8&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M205.76,-296.05C199.47,-314.72 190.61,-336.65 181.17,-346.18"/>
-<polygon fill="red" stroke="red" points="179.22,-343.25 172,-351 182.48,-349.44 179.22,-343.25"/>
-<text text-anchor="middle" x="202.76" y="-298.65" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- If8&#45;&gt;Con_7 -->
-<g id="edge5" class="edge">
-<title>If8&#45;&gt;Con_7</title>
-<path fill="none" stroke="black" d="M219.43,-296.01C221.25,-308.76 223.34,-323.4 225.1,-335.73"/>
-<polygon fill="black" stroke="black" points="221.67,-336.47 226.55,-345.87 228.6,-335.48 221.67,-336.47"/>
-<text text-anchor="middle" x="216.43" y="-298.61" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_12 -->
-<g id="node6" class="node">
-<title>Con_12</title>
-<ellipse fill="none" stroke="black" cx="43" cy="-264" rx="27" ry="18"/>
-<text text-anchor="middle" x="43" y="-260.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- Con_13 -->
-<g id="node7" class="node">
-<title>Con_13</title>
-<ellipse fill="none" stroke="black" cx="115" cy="-264" rx="27" ry="18"/>
-<text text-anchor="middle" x="115" y="-260.3" font-family="Times,serif" font-size="14.00">#3</text>
-</g>
-<!-- Region14&#45;&gt;If8 -->
-<g id="edge6" class="edge">
-<title>Region14&#45;&gt;If8:p0</title>
-<path fill="none" stroke="red" d="M193,-196.09C193,-205.55 193,-217.77 193,-229.69"/>
-<polygon fill="red" stroke="red" points="189.5,-230 193,-240 196.5,-230 189.5,-230"/>
-<text text-anchor="middle" x="190" y="-198.69" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Region14&#45;&gt;If8 -->
-<g id="edge7" class="edge">
-<title>Region14&#45;&gt;If8:p1</title>
-<path fill="none" stroke="red" d="M213.02,-196.12C221.64,-205.06 230.48,-216.84 233.71,-229.84"/>
-<polygon fill="red" stroke="red" points="230.27,-230.52 235,-240 237.22,-229.64 230.27,-230.52"/>
-<text text-anchor="middle" x="210.02" y="-198.72" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_a15&#45;&gt;Con_12 -->
-<g id="edge9" class="edge">
-<title>Phi_a15&#45;&gt;Con_12</title>
-<path fill="none" stroke="black" d="M102.13,-194.02C91.07,-206.92 74.96,-225.71 62.35,-240.42"/>
-<polygon fill="black" stroke="black" points="59.61,-238.24 55.76,-248.11 64.93,-242.8 59.61,-238.24"/>
-<text text-anchor="middle" x="99.13" y="-196.62" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_a15&#45;&gt;Con_13 -->
-<g id="edge10" class="edge">
-<title>Phi_a15&#45;&gt;Con_13</title>
-<path fill="none" stroke="black" d="M115,-196.4C115,-207.74 115,-222.77 115,-235.68"/>
-<polygon fill="black" stroke="black" points="111.5,-235.9 115,-245.9 118.5,-235.9 111.5,-235.9"/>
-<text text-anchor="middle" x="112" y="-199" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_a15&#45;&gt;Region14 -->
-<g id="edge8" class="edge">
-<title>Phi_a15&#45;&gt;Region14</title>
-<path fill="none" stroke="black" stroke-dasharray="1,5" d="M142.12,-178C144.58,-178 147.04,-178 149.5,-178"/>
-<polygon fill="black" stroke="black" points="149.61,-181.5 159.61,-178 149.61,-174.5 149.61,-181.5"/>
-<text text-anchor="middle" x="145.12" y="-171.6" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="662" height="628" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 662 628" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"><g class="region" transform="translate(24,171)"><rect class="region-box" rx="8" width="360" height="250" fill="#f2f7ef"/></g></g><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M180,527 C180,551 331,554 331,578" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #16 · CTRL</title></path><path class="edge CTRL" id="e8i0" d="M116,118 L116,205" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#8[0] → #1 · CTRL</title></path><path class="edge DATA" id="e8i1" d="M274,118 L274,128 L196,128 L196,205" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#8[1] → #7 · DATA</title></path><path class="edge CTRL" id="e14i1" d="M96,305 L96,315 L160,315 L160,353" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#14[1] → #4 · CTRL</title></path><path class="edge CTRL" id="e14i2" d="M216,305 L216,315 L190,315 L190,353" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#14[2] → #5 · CTRL</title></path><path class="edge DATA" id="e15i1" d="M426,118 L426,128 L292,128 L292,353" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#15[1] → #12 · DATA</title></path><path class="edge DATA" id="e15i2" d="M578,118 L578,138 L332,138 L332,353" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#15[2] → #13 · DATA</title></path><path class="edge CTRL" id="e16i0" d="M160,409 L160,474" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#16[0] → #14 · CTRL</title></path><path class="edge DATA" id="e16i1" d="M312,409 L312,436 L200,436 L200,474" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#16[1] → #15 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(56,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(56,24)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(295,578)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #16 CTRL</title><circle class="port" cx="36" cy="0" r="3" fill="#536477"/><text class="slot" x="36" y="-7" text-anchor="middle">0</text></g><g class="node" id="n4" data-id="4" transform="translate(36,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>True</tspan><tspan class="node-id">  #4/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#4 True
+Projection 0 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n5" data-id="5" transform="translate(156,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>False</tspan><tspan class="node-id">  #5/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#5 False
+Projection 1 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n7" data-id="7" transform="translate(214,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#1</tspan><tspan class="node-id">  #7</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#7 #1
+Type not computed
+
+</title></g><g class="node" id="n8" data-id="8" transform="translate(36,211)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#8 If
+Type not computed
+
+[0] → #1 CTRL
+[1] → #7 DATA</title><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><circle class="port" cx="160" cy="-3" r="3" fill="#536477"/><text class="slot" x="80" y="-10" text-anchor="middle">0</text><text class="slot" x="160" y="-10" text-anchor="middle">1</text></g><g class="node" id="n12" data-id="12" transform="translate(366,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #12</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#12 #2
+Type not computed
+
+</title></g><g class="node" id="n13" data-id="13" transform="translate(518,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#3</tspan><tspan class="node-id">  #13</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#13 #3
+Type not computed
+
+</title></g><g class="node" id="n14" data-id="14" transform="translate(100,359)" style="opacity: 1;"><path class="box" d="M12,0H108L120,44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Region</tspan><tspan class="node-id">  #14</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#14 Region
+Type not computed
+
+[0] → — DATA
+[1] → #4 CTRL
+[2] → #5 CTRL</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n15" data-id="15" transform="translate(252,359)" style="opacity: 1;"><path class="box" d="M12,0H108L120,22L108,44H12L0,22Z" fill="#f5e4fa"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>φ_a</tspan><tspan class="node-id">  #15</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#15 φ_a
+Type not computed
+
+[0] → #14 ASSOC
+[1] → #12 DATA
+[2] → #13 DATA</title><circle class="port" cx="-3" cy="22" r="3" fill="#536477"/><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><path class="reg" fill="none" stroke="#b63838" d="M-3,22H-18m4,-3l-4,3l4,3"><title>[0] → #14</title></path><text class="slot" x="-10" y="15" text-anchor="middle">0</text><text class="slot" x="40" y="-10" text-anchor="middle">1</text><text class="slot" x="80" y="-10" text-anchor="middle">2</text></g><g class="node" id="n16" data-id="16" transform="translate(120,480)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #16</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#16 Return
+Type not computed
+
+[0] → #14 CTRL
+[1] → #15 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"><g class="region-head" transform="translate(24,171)"><text class="label" x="26" y="17"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><title>If · 5 nodes</title><g class="fold-btn" role="button" tabindex="0" transform="translate(4,4)" aria-label="Fold region #8"><rect width="16" height="16" rx="2"/><text x="8" y="12" text-anchor="middle">−</text><title>Fold region</title></g></g></g><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/06-graph3-nonconst-peephole.json b/chapter06/docs/06-graph3-nonconst-peephole.json
new file mode 100644
index 00000000..7f1f183c
--- /dev/null
+++ b/chapter06/docs/06-graph3-nonconst-peephole.json
@@ -0,0 +1,24 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph3-nonconst-peephole.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 31, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 4, "label": "arg", "type": null, "kind": "DATA", "edges": [{"idx": 0, "def": 2, "role": "DATA", "label": null}], "proj": {"par": 2, "idx": 1}},
+ {"id": 5, "label": "True", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 0}},
+ {"id": 6, "label": "False", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 1}},
+ {"id": 8, "label": "If", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 4, "role": "DATA", "label": null}], "proj": null},
+ {"id": 22, "label": "Region", "type": null, "kind": "REGION", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 5, "role": "CTRL", "label": null}, {"idx": 2, "def": 6, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 27, "label": "#4", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 29, "label": "#1", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 30, "label": "φ_ab", "type": null, "kind": "PHI", "edges": [{"idx": 0, "def": 22, "role": "ASSOC", "label": null}, {"idx": 1, "def": 27, "role": "DATA", "label": null}, {"idx": 2, "def": 29, "role": "DATA", "label": null}], "proj": null},
+ {"id": 31, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 22, "role": "CTRL", "label": null}, {"idx": 1, "def": 30, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ {"id": 8, "par": 0, "nodes": [5, 6, 8, 22, 30]}
+ ]
+}
diff --git a/chapter06/docs/06-graph3-nonconst-peephole.svg b/chapter06/docs/06-graph3-nonconst-peephole.svg
index c312ffc5..85728510 100644
--- a/chapter06/docs/06-graph3-nonconst-peephole.svg
+++ b/chapter06/docs/06-graph3-nonconst-peephole.svg
@@ -1,150 +1,109 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="294pt" height="420pt"
- viewBox="0.00 0.00 294.00 420.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 416)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-416 290,-416 290,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-404 278,-404 278,-8 8,-8"/>
-</g>
-<!-- Start2 -->
-<g id="node1" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="168,-367 168,-392 249,-392 249,-367 168,-367"/>
-<polygon fill="none" stroke="black" points="168,-367 168,-392 249,-392 249,-367 168,-367"/>
-<text text-anchor="start" x="190" y="-375.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="168,-336 168,-367 249,-367 249,-336 168,-336"/>
-<polygon fill="yellow" stroke="transparent" points="173,-341 173,-362 213,-362 213,-341 173,-341"/>
-<polygon fill="none" stroke="black" points="173,-341 173,-362 213,-362 213,-341 173,-341"/>
-<text text-anchor="start" x="176" y="-347.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-<polygon fill="none" stroke="black" points="213,-341 213,-362 244,-362 244,-341 213,-341"/>
-<text text-anchor="start" x="216" y="-347.8" font-family="Times,serif" font-size="14.00">arg</text>
-</g>
-<!-- Stop3 -->
-<g id="node2" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="180,-52 126,-52 126,-16 180,-16 180,-52"/>
-<text text-anchor="middle" x="153" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Return31 -->
-<g id="node8" class="node">
-<title>Return31</title>
-<polygon fill="yellow" stroke="black" points="186,-124 120,-124 120,-88 186,-88 186,-124"/>
-<text text-anchor="middle" x="153" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Stop3&#45;&gt;Return31 -->
-<g id="edge1" class="edge">
-<title>Stop3&#45;&gt;Return31</title>
-<path fill="none" stroke="red" d="M153,-52.3C153,-60.02 153,-69.29 153,-77.89"/>
-<polygon fill="red" stroke="red" points="149.5,-77.9 153,-87.9 156.5,-77.9 149.5,-77.9"/>
-<text text-anchor="middle" x="150" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Region22 -->
-<g id="node3" class="node">
-<title>Region22</title>
-<polygon fill="yellow" stroke="black" points="228,-196 162,-196 162,-160 228,-160 228,-196"/>
-<text text-anchor="middle" x="195" y="-174.3" font-family="Times,serif" font-size="14.00">Region</text>
-</g>
-<!-- If8 -->
-<g id="node4" class="node">
-<title>If8</title>
-<polygon fill="yellow" stroke="transparent" points="168,-267 168,-292 262,-292 262,-267 168,-267"/>
-<polygon fill="none" stroke="black" points="168,-267 168,-292 262,-292 262,-267 168,-267"/>
-<text text-anchor="start" x="209.5" y="-275.8" font-family="Times,serif" font-size="14.00">If</text>
-<polygon fill="none" stroke="black" points="168,-236 168,-267 262,-267 262,-236 168,-236"/>
-<polygon fill="yellow" stroke="transparent" points="173,-241 173,-262 213,-262 213,-241 173,-241"/>
-<polygon fill="none" stroke="black" points="173,-241 173,-262 213,-262 213,-241 173,-241"/>
-<text text-anchor="start" x="176" y="-247.8" font-family="Times,serif" font-size="14.00">True</text>
-<polygon fill="yellow" stroke="transparent" points="213,-241 213,-262 257,-262 257,-241 213,-241"/>
-<polygon fill="none" stroke="black" points="213,-241 213,-262 257,-262 257,-241 213,-241"/>
-<text text-anchor="start" x="216" y="-247.8" font-family="Times,serif" font-size="14.00">False</text>
-</g>
-<!-- Region22&#45;&gt;If8 -->
-<g id="edge2" class="edge">
-<title>Region22&#45;&gt;If8:p0</title>
-<path fill="none" stroke="red" d="M194.14,-196.09C193.72,-205.54 193.27,-217.77 193.08,-229.68"/>
-<polygon fill="red" stroke="red" points="189.58,-229.97 193,-240 196.58,-230.03 189.58,-229.97"/>
-<text text-anchor="middle" x="191.14" y="-198.69" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Region22&#45;&gt;If8 -->
-<g id="edge3" class="edge">
-<title>Region22&#45;&gt;If8:p1</title>
-<path fill="none" stroke="red" d="M213.83,-196.05C222.1,-205.05 230.63,-216.92 233.76,-229.89"/>
-<polygon fill="red" stroke="red" points="230.31,-230.5 235,-240 237.25,-229.65 230.31,-230.5"/>
-<text text-anchor="middle" x="210.83" y="-198.65" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- If8&#45;&gt;Start2 -->
-<g id="edge4" class="edge">
-<title>If8&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M201.57,-296.16C198.03,-306.41 194.84,-318.18 193.57,-329.83"/>
-<polygon fill="red" stroke="red" points="190.07,-329.82 193,-340 197.06,-330.21 190.07,-329.82"/>
-<text text-anchor="middle" x="198.57" y="-298.76" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- If8&#45;&gt;Start2 -->
-<g id="edge5" class="edge">
-<title>If8&#45;&gt;Start2:p1</title>
-<path fill="none" stroke="black" d="M223.47,-296.14C225.75,-306.5 227.81,-318.36 228.63,-329.94"/>
-<polygon fill="black" stroke="black" points="225.13,-330.14 229,-340 232.13,-329.88 225.13,-330.14"/>
-<text text-anchor="middle" x="220.47" y="-298.74" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_27 -->
-<g id="node5" class="node">
-<title>Con_27</title>
-<ellipse fill="none" stroke="black" cx="43" cy="-264" rx="27" ry="18"/>
-<text text-anchor="middle" x="43" y="-260.3" font-family="Times,serif" font-size="14.00">#4</text>
-</g>
-<!-- Con_29 -->
-<g id="node6" class="node">
-<title>Con_29</title>
-<ellipse fill="none" stroke="black" cx="115" cy="-264" rx="27" ry="18"/>
-<text text-anchor="middle" x="115" y="-260.3" font-family="Times,serif" font-size="14.00">#1</text>
-</g>
-<!-- Phi_ab30 -->
-<g id="node7" class="node">
-<title>Phi_ab30</title>
-<ellipse fill="lightyellow" stroke="black" cx="112" cy="-178" rx="32.49" ry="18"/>
-<text text-anchor="middle" x="112" y="-174.3" font-family="Times,serif" font-size="14.00">φ_ab</text>
-</g>
-<!-- Phi_ab30&#45;&gt;Region22 -->
-<g id="edge6" class="edge">
-<title>Phi_ab30&#45;&gt;Region22</title>
-<path fill="none" stroke="black" stroke-dasharray="1,5" d="M144.75,-178C147.03,-178 149.32,-178 151.6,-178"/>
-<polygon fill="black" stroke="black" points="151.63,-181.5 161.63,-178 151.63,-174.5 151.63,-181.5"/>
-<text text-anchor="middle" x="147.75" y="-171.6" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Phi_ab30&#45;&gt;Con_27 -->
-<g id="edge7" class="edge">
-<title>Phi_ab30&#45;&gt;Con_27</title>
-<path fill="none" stroke="black" d="M99.02,-194.8C88.58,-207.51 73.76,-225.56 61.98,-239.89"/>
-<polygon fill="black" stroke="black" points="59.1,-237.89 55.46,-247.84 64.51,-242.33 59.1,-237.89"/>
-<text text-anchor="middle" x="96.02" y="-197.4" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_ab30&#45;&gt;Con_29 -->
-<g id="edge8" class="edge">
-<title>Phi_ab30&#45;&gt;Con_29</title>
-<path fill="none" stroke="black" d="M112.61,-196C113.01,-207.31 113.55,-222.42 114.02,-235.43"/>
-<polygon fill="black" stroke="black" points="110.53,-235.87 114.38,-245.74 117.52,-235.62 110.53,-235.87"/>
-<text text-anchor="middle" x="109.61" y="-198.6" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Return31&#45;&gt;Region22 -->
-<g id="edge9" class="edge">
-<title>Return31&#45;&gt;Region22</title>
-<path fill="none" stroke="red" d="M163.38,-124.3C168.26,-132.44 174.19,-142.31 179.58,-151.3"/>
-<polygon fill="red" stroke="red" points="176.59,-153.12 184.74,-159.9 182.59,-149.52 176.59,-153.12"/>
-<text text-anchor="middle" x="160.38" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return31&#45;&gt;Phi_ab30 -->
-<g id="edge10" class="edge">
-<title>Return31&#45;&gt;Phi_ab30</title>
-<path fill="none" stroke="black" d="M142.87,-124.3C138.03,-132.56 132.15,-142.61 126.82,-151.7"/>
-<polygon fill="black" stroke="black" points="123.77,-149.98 121.74,-160.38 129.81,-153.52 123.77,-149.98"/>
-<text text-anchor="middle" x="139.87" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="630" height="628" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 630 628" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"><g class="region" transform="translate(24,171)"><rect class="region-box" rx="8" width="360" height="250" fill="#f2f7ef"/></g></g><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M180,527 C180,551 315,554 315,578" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #31 · CTRL</title></path><path class="edge CTRL" id="e8i0" d="M116,118 L116,205" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#8[0] → #1 · CTRL</title></path><path class="edge DATA" id="e8i1" d="M236,118 L236,128 L196,128 L196,205" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#8[1] → #4 · DATA</title></path><path class="edge CTRL" id="e22i1" d="M96,305 L96,315 L160,315 L160,353" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#22[1] → #5 · CTRL</title></path><path class="edge CTRL" id="e22i2" d="M216,305 L216,315 L190,315 L190,353" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#22[2] → #6 · CTRL</title></path><path class="edge DATA" id="e30i1" d="M394,118 L394,128 L292,128 L292,353" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#30[1] → #27 · DATA</title></path><path class="edge DATA" id="e30i2" d="M546,118 L546,138 L332,138 L332,353" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#30[2] → #29 · DATA</title></path><path class="edge CTRL" id="e31i0" d="M160,409 L160,474" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#31[0] → #22 · CTRL</title></path><path class="edge DATA" id="e31i1" d="M312,409 L312,436 L200,436 L200,474" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#31[1] → #30 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(56,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(56,24)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(279,578)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #31 CTRL</title><circle class="port" cx="36" cy="0" r="3" fill="#536477"/><text class="slot" x="36" y="-7" text-anchor="middle">0</text></g><g class="node" id="n4" data-id="4" transform="translate(176,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>arg</tspan><tspan class="node-id">  #4/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#4 arg
+Projection 1 of #2
+Type not computed
+
+[0] → #2 DATA</title></g><g class="node" id="n5" data-id="5" transform="translate(36,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>True</tspan><tspan class="node-id">  #5/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#5 True
+Projection 0 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n6" data-id="6" transform="translate(156,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>False</tspan><tspan class="node-id">  #6/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#6 False
+Projection 1 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n8" data-id="8" transform="translate(36,211)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#8 If
+Type not computed
+
+[0] → #1 CTRL
+[1] → #4 DATA</title><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><circle class="port" cx="160" cy="-3" r="3" fill="#536477"/><text class="slot" x="80" y="-10" text-anchor="middle">0</text><text class="slot" x="160" y="-10" text-anchor="middle">1</text></g><g class="node" id="n22" data-id="22" transform="translate(100,359)" style="opacity: 1;"><path class="box" d="M12,0H108L120,44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Region</tspan><tspan class="node-id">  #22</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#22 Region
+Type not computed
+
+[0] → — DATA
+[1] → #5 CTRL
+[2] → #6 CTRL</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n27" data-id="27" transform="translate(334,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#4</tspan><tspan class="node-id">  #27</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#27 #4
+Type not computed
+
+</title></g><g class="node" id="n29" data-id="29" transform="translate(486,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#1</tspan><tspan class="node-id">  #29</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#29 #1
+Type not computed
+
+</title></g><g class="node" id="n30" data-id="30" transform="translate(252,359)" style="opacity: 1;"><path class="box" d="M12,0H108L120,22L108,44H12L0,22Z" fill="#f5e4fa"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>φ_ab</tspan><tspan class="node-id">  #30</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#30 φ_ab
+Type not computed
+
+[0] → #22 ASSOC
+[1] → #27 DATA
+[2] → #29 DATA</title><circle class="port" cx="-3" cy="22" r="3" fill="#536477"/><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><path class="reg" fill="none" stroke="#b63838" d="M-3,22H-18m4,-3l-4,3l4,3"><title>[0] → #22</title></path><text class="slot" x="-10" y="15" text-anchor="middle">0</text><text class="slot" x="40" y="-10" text-anchor="middle">1</text><text class="slot" x="80" y="-10" text-anchor="middle">2</text></g><g class="node" id="n31" data-id="31" transform="translate(120,480)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #31</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#31 Return
+Type not computed
+
+[0] → #22 CTRL
+[1] → #30 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"><g class="region-head" transform="translate(24,171)"><text class="label" x="26" y="17"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><title>If · 5 nodes</title><g class="fold-btn" role="button" tabindex="0" transform="translate(4,4)" aria-label="Fold region #8"><rect width="16" height="16" rx="2"/><text x="8" y="12" text-anchor="middle">−</text><title>Fold region</title></g></g></g><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/06-graph3-nonconst.json b/chapter06/docs/06-graph3-nonconst.json
new file mode 100644
index 00000000..77bb6d2c
--- /dev/null
+++ b/chapter06/docs/06-graph3-nonconst.json
@@ -0,0 +1,35 @@
+{
+ "ver": 1,
+ "comp": "chapter06/docs/06-graph3-nonconst.svg",
+ "step": 1,
+ "roots": [],
+ "scope": 0,
+ "nodes": [
+ {"id": 1, "label": "$ctrl", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 2, "role": "CTRL", "label": null}], "proj": {"par": 2, "idx": 0}},
+ {"id": 2, "label": "Start", "type": null, "kind": "CTRL", "edges": [], "proj": null},
+ {"id": 3, "label": "Stop", "type": null, "kind": "STOP", "edges": [{"idx": 0, "def": 25, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 4, "label": "arg", "type": null, "kind": "DATA", "edges": [{"idx": 0, "def": 2, "role": "DATA", "label": null}], "proj": {"par": 2, "idx": 1}},
+ {"id": 5, "label": "True", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 0}},
+ {"id": 6, "label": "#0", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 7, "label": "#1", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 8, "label": "If", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 1, "role": "CTRL", "label": null}, {"idx": 1, "def": 4, "role": "DATA", "label": null}], "proj": null},
+ {"id": 9, "label": "False", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 8, "role": "CTRL", "label": null}], "proj": {"par": 8, "idx": 1}},
+ {"id": 10, "label": "True", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 13, "role": "CTRL", "label": null}], "proj": {"par": 13, "idx": 0}},
+ {"id": 11, "label": "False", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 13, "role": "CTRL", "label": null}], "proj": {"par": 13, "idx": 1}},
+ {"id": 12, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 13, "label": "If", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 5, "role": "CTRL", "label": null}, {"idx": 1, "def": 4, "role": "DATA", "label": null}], "proj": null},
+ {"id": 17, "label": "#2", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 18, "label": "#3", "type": null, "kind": "DATA", "edges": [], "proj": null},
+ {"id": 19, "label": "Region", "type": null, "kind": "REGION", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 10, "role": "CTRL", "label": null}, {"idx": 2, "def": 11, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 20, "label": "φ_b", "type": null, "kind": "PHI", "edges": [{"idx": 0, "def": 19, "role": "ASSOC", "label": null}, {"idx": 1, "def": 17, "role": "DATA", "label": null}, {"idx": 2, "def": 18, "role": "DATA", "label": null}], "proj": null},
+ {"id": 21, "label": "Region", "type": null, "kind": "REGION", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 19, "role": "CTRL", "label": null}, {"idx": 2, "def": 9, "role": "CTRL", "label": null}], "proj": null},
+ {"id": 22, "label": "φ_a", "type": null, "kind": "PHI", "edges": [{"idx": 0, "def": 21, "role": "ASSOC", "label": null}, {"idx": 1, "def": 12, "role": "DATA", "label": null}, {"idx": 2, "def": 6, "role": "DATA", "label": null}], "proj": null},
+ {"id": 23, "label": "φ_b", "type": null, "kind": "PHI", "edges": [{"idx": 0, "def": 21, "role": "ASSOC", "label": null}, {"idx": 1, "def": 20, "role": "DATA", "label": null}, {"idx": 2, "def": 7, "role": "DATA", "label": null}], "proj": null},
+ {"id": 24, "label": "+", "type": null, "kind": "DATA", "edges": [{"idx": 0, "def": 0, "role": "DATA", "label": null}, {"idx": 1, "def": 23, "role": "DATA", "label": null}, {"idx": 2, "def": 22, "role": "DATA", "label": null}], "proj": null},
+ {"id": 25, "label": "Return", "type": null, "kind": "CTRL", "edges": [{"idx": 0, "def": 21, "role": "CTRL", "label": null}, {"idx": 1, "def": 24, "role": "DATA", "label": null}], "proj": null}
+ ],
+ "groups": [
+ {"id": 8, "par": 0, "nodes": [5, 8, 9, 21, 22, 23, 24]},
+ {"id": 13, "par": 8, "nodes": [10, 11, 13, 19, 20]}
+ ]
+}
diff --git a/chapter06/docs/06-graph3-nonconst.svg b/chapter06/docs/06-graph3-nonconst.svg
index dee852e4..d46d4bb1 100644
--- a/chapter06/docs/06-graph3-nonconst.svg
+++ b/chapter06/docs/06-graph3-nonconst.svg
@@ -1,290 +1,150 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
- "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
-<!-- Generated by graphviz version 2.43.0 (0)
- -->
-<!-- Title: chapter06 Pages: 1 -->
-<svg width="414pt" height="664pt"
- viewBox="0.00 0.00 414.00 664.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 660)">
-<title>chapter06</title>
-<polygon fill="white" stroke="transparent" points="-4,4 -4,-660 410,-660 410,4 -4,4"/>
-<g id="clust1" class="cluster">
-<title>cluster_Nodes</title>
-<polygon fill="none" stroke="black" points="8,-8 8,-648 398,-648 398,-8 8,-8"/>
-</g>
-<!-- Start2 -->
-<g id="node1" class="node">
-<title>Start2</title>
-<polygon fill="yellow" stroke="transparent" points="274,-611 274,-636 355,-636 355,-611 274,-611"/>
-<polygon fill="none" stroke="black" points="274,-611 274,-636 355,-636 355,-611 274,-611"/>
-<text text-anchor="start" x="296" y="-619.8" font-family="Times,serif" font-size="14.00">Start</text>
-<polygon fill="none" stroke="black" points="274,-580 274,-611 355,-611 355,-580 274,-580"/>
-<polygon fill="yellow" stroke="transparent" points="279,-585 279,-606 319,-606 319,-585 279,-585"/>
-<polygon fill="none" stroke="black" points="279,-585 279,-606 319,-606 319,-585 279,-585"/>
-<text text-anchor="start" x="282" y="-591.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
-<polygon fill="none" stroke="black" points="319,-585 319,-606 350,-606 350,-585 319,-585"/>
-<text text-anchor="start" x="322" y="-591.8" font-family="Times,serif" font-size="14.00">arg</text>
-</g>
-<!-- Stop3 -->
-<g id="node2" class="node">
-<title>Stop3</title>
-<polygon fill="yellow" stroke="black" points="299,-52 245,-52 245,-16 299,-16 299,-52"/>
-<text text-anchor="middle" x="272" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
-</g>
-<!-- Return25 -->
-<g id="node16" class="node">
-<title>Return25</title>
-<polygon fill="yellow" stroke="black" points="305,-124 239,-124 239,-88 305,-88 305,-124"/>
-<text text-anchor="middle" x="272" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
-</g>
-<!-- Stop3&#45;&gt;Return25 -->
-<g id="edge1" class="edge">
-<title>Stop3&#45;&gt;Return25</title>
-<path fill="none" stroke="red" d="M272,-52.3C272,-60.02 272,-69.29 272,-77.89"/>
-<polygon fill="red" stroke="red" points="268.5,-77.9 272,-87.9 275.5,-77.9 268.5,-77.9"/>
-<text text-anchor="middle" x="269" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Con_6 -->
-<g id="node3" class="node">
-<title>Con_6</title>
-<ellipse fill="none" stroke="black" cx="259" cy="-322" rx="27" ry="18"/>
-<text text-anchor="middle" x="259" y="-318.3" font-family="Times,serif" font-size="14.00">#0</text>
-</g>
-<!-- Con_7 -->
-<g id="node4" class="node">
-<title>Con_7</title>
-<ellipse fill="none" stroke="black" cx="115" cy="-322" rx="27" ry="18"/>
-<text text-anchor="middle" x="115" y="-318.3" font-family="Times,serif" font-size="14.00">#1</text>
-</g>
-<!-- If8 -->
-<g id="node5" class="node">
-<title>If8</title>
-<polygon fill="yellow" stroke="transparent" points="288,-511 288,-536 382,-536 382,-511 288,-511"/>
-<polygon fill="none" stroke="black" points="288,-511 288,-536 382,-536 382,-511 288,-511"/>
-<text text-anchor="start" x="329.5" y="-519.8" font-family="Times,serif" font-size="14.00">If</text>
-<polygon fill="none" stroke="black" points="288,-480 288,-511 382,-511 382,-480 288,-480"/>
-<polygon fill="yellow" stroke="transparent" points="293,-485 293,-506 333,-506 333,-485 293,-485"/>
-<polygon fill="none" stroke="black" points="293,-485 293,-506 333,-506 333,-485 293,-485"/>
-<text text-anchor="start" x="296" y="-491.8" font-family="Times,serif" font-size="14.00">True</text>
-<polygon fill="yellow" stroke="transparent" points="333,-485 333,-506 377,-506 377,-485 333,-485"/>
-<polygon fill="none" stroke="black" points="333,-485 333,-506 377,-506 377,-485 333,-485"/>
-<text text-anchor="start" x="336" y="-491.8" font-family="Times,serif" font-size="14.00">False</text>
-</g>
-<!-- If8&#45;&gt;Start2 -->
-<g id="edge2" class="edge">
-<title>If8&#45;&gt;Start2:p0</title>
-<path fill="none" stroke="red" d="M312.41,-540.3C306.75,-550.38 301.75,-562.04 299.83,-573.96"/>
-<polygon fill="red" stroke="red" points="296.34,-573.75 299,-584 303.31,-574.32 296.34,-573.75"/>
-<text text-anchor="middle" x="309.41" y="-542.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- If8&#45;&gt;Start2 -->
-<g id="edge3" class="edge">
-<title>If8&#45;&gt;Start2:p1</title>
-<path fill="none" stroke="black" d="M335,-540.02C335,-550.47 335,-562.42 335,-573.98"/>
-<polygon fill="black" stroke="black" points="331.5,-574 335,-584 338.5,-574 331.5,-574"/>
-<text text-anchor="middle" x="332" y="-542.62" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Con_12 -->
-<g id="node6" class="node">
-<title>Con_12</title>
-<ellipse fill="none" stroke="black" cx="187" cy="-322" rx="27" ry="18"/>
-<text text-anchor="middle" x="187" y="-318.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- If13 -->
-<g id="node7" class="node">
-<title>If13</title>
-<polygon fill="yellow" stroke="transparent" points="267,-411 267,-436 361,-436 361,-411 267,-411"/>
-<polygon fill="none" stroke="black" points="267,-411 267,-436 361,-436 361,-411 267,-411"/>
-<text text-anchor="start" x="308.5" y="-419.8" font-family="Times,serif" font-size="14.00">If</text>
-<polygon fill="none" stroke="black" points="267,-380 267,-411 361,-411 361,-380 267,-380"/>
-<polygon fill="yellow" stroke="transparent" points="272,-385 272,-406 312,-406 312,-385 272,-385"/>
-<polygon fill="none" stroke="black" points="272,-385 272,-406 312,-406 312,-385 272,-385"/>
-<text text-anchor="start" x="275" y="-391.8" font-family="Times,serif" font-size="14.00">True</text>
-<polygon fill="yellow" stroke="transparent" points="312,-385 312,-406 356,-406 356,-385 312,-385"/>
-<polygon fill="none" stroke="black" points="312,-385 312,-406 356,-406 356,-385 312,-385"/>
-<text text-anchor="start" x="315" y="-391.8" font-family="Times,serif" font-size="14.00">False</text>
-</g>
-<!-- If13&#45;&gt;Start2 -->
-<g id="edge5" class="edge">
-<title>If13&#45;&gt;Start2:p1</title>
-<path fill="none" stroke="black" d="M288.75,-440.22C281.57,-450.93 274.7,-463.4 271,-476 262.99,-503.29 257.76,-514.83 271,-540 285.19,-566.97 324.2,-553.71 333.15,-573.98"/>
-<polygon fill="black" stroke="black" points="329.75,-574.8 335,-584 336.63,-573.53 329.75,-574.8"/>
-<text text-anchor="middle" x="285.75" y="-442.82" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- If13&#45;&gt;If8 -->
-<g id="edge4" class="edge">
-<title>If13&#45;&gt;If8:p0</title>
-<path fill="none" stroke="red" d="M313.4,-440.02C313.24,-450.46 313.09,-462.42 313.03,-473.98"/>
-<polygon fill="red" stroke="red" points="309.53,-473.99 313,-484 316.53,-474.01 309.53,-473.99"/>
-<text text-anchor="middle" x="310.4" y="-442.62" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Con_17 -->
-<g id="node8" class="node">
-<title>Con_17</title>
-<ellipse fill="none" stroke="black" cx="43" cy="-408" rx="27" ry="18"/>
-<text text-anchor="middle" x="43" y="-404.3" font-family="Times,serif" font-size="14.00">#2</text>
-</g>
-<!-- Con_18 -->
-<g id="node9" class="node">
-<title>Con_18</title>
-<ellipse fill="none" stroke="black" cx="115" cy="-408" rx="27" ry="18"/>
-<text text-anchor="middle" x="115" y="-404.3" font-family="Times,serif" font-size="14.00">#3</text>
-</g>
-<!-- Region19 -->
-<g id="node10" class="node">
-<title>Region19</title>
-<polygon fill="yellow" stroke="black" points="370,-340 304,-340 304,-304 370,-304 370,-340"/>
-<text text-anchor="middle" x="337" y="-318.3" font-family="Times,serif" font-size="14.00">Region</text>
-</g>
-<!-- Region19&#45;&gt;If13 -->
-<g id="edge6" class="edge">
-<title>Region19&#45;&gt;If13:p0</title>
-<path fill="none" stroke="red" d="M315.29,-340.1C306.12,-348.94 296.78,-360.62 293.36,-373.72"/>
-<polygon fill="red" stroke="red" points="289.84,-373.63 292,-384 296.78,-374.54 289.84,-373.63"/>
-<text text-anchor="middle" x="312.29" y="-342.7" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Region19&#45;&gt;If13 -->
-<g id="edge7" class="edge">
-<title>Region19&#45;&gt;If13:p1</title>
-<path fill="none" stroke="red" d="M335.71,-340.08C335.08,-349.53 334.4,-361.76 334.13,-373.68"/>
-<polygon fill="red" stroke="red" points="330.62,-373.96 334,-384 337.62,-374.04 330.62,-373.96"/>
-<text text-anchor="middle" x="332.71" y="-342.68" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_b20 -->
-<g id="node11" class="node">
-<title>Phi_b20</title>
-<ellipse fill="lightyellow" stroke="black" cx="43" cy="-322" rx="27.1" ry="18"/>
-<text text-anchor="middle" x="43" y="-318.3" font-family="Times,serif" font-size="14.00">φ_b</text>
-</g>
-<!-- Phi_b20&#45;&gt;Con_17 -->
-<g id="edge9" class="edge">
-<title>Phi_b20&#45;&gt;Con_17</title>
-<path fill="none" stroke="black" d="M43,-340.4C43,-351.74 43,-366.77 43,-379.68"/>
-<polygon fill="black" stroke="black" points="39.5,-379.9 43,-389.9 46.5,-379.9 39.5,-379.9"/>
-<text text-anchor="middle" x="40" y="-343" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_b20&#45;&gt;Con_18 -->
-<g id="edge10" class="edge">
-<title>Phi_b20&#45;&gt;Con_18</title>
-<path fill="none" stroke="black" d="M55.87,-338.02C66.93,-350.92 83.04,-369.71 95.65,-384.42"/>
-<polygon fill="black" stroke="black" points="93.07,-386.8 102.24,-392.11 98.39,-382.24 93.07,-386.8"/>
-<text text-anchor="middle" x="52.87" y="-340.62" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_b20&#45;&gt;Region19 -->
-<g id="edge8" class="edge">
-<title>Phi_b20&#45;&gt;Region19</title>
-<path fill="none" stroke="black" stroke-dasharray="1,5" d="M57.22,-306.43C65.37,-298.68 76.29,-290.11 88,-286 129.52,-271.44 244.06,-272.69 286,-286 293.99,-288.54 301.81,-292.83 308.83,-297.58"/>
-<polygon fill="black" stroke="black" points="307.11,-300.66 317.24,-303.75 311.25,-295.01 307.11,-300.66"/>
-<text text-anchor="middle" x="54.22" y="-300.03" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Region21 -->
-<g id="node12" class="node">
-<title>Region21</title>
-<polygon fill="yellow" stroke="black" points="352,-268 286,-268 286,-232 352,-232 352,-268"/>
-<text text-anchor="middle" x="319" y="-246.3" font-family="Times,serif" font-size="14.00">Region</text>
-</g>
-<!-- Region21&#45;&gt;If8 -->
-<g id="edge12" class="edge">
-<title>Region21&#45;&gt;If8:p1</title>
-<path fill="none" stroke="red" d="M347.26,-268.03C359.43,-277.04 372.37,-289.3 379,-304 385.58,-318.6 394.79,-373.07 378,-440 373.59,-457.56 360.94,-461.07 356.53,-473.94"/>
-<polygon fill="red" stroke="red" points="353.05,-473.59 355,-484 359.97,-474.64 353.05,-473.59"/>
-<text text-anchor="middle" x="344.26" y="-270.63" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Region21&#45;&gt;Region19 -->
-<g id="edge11" class="edge">
-<title>Region21&#45;&gt;Region19</title>
-<path fill="none" stroke="red" d="M323.45,-268.3C325.45,-276.1 327.87,-285.49 330.1,-294.17"/>
-<polygon fill="red" stroke="red" points="326.72,-295.08 332.6,-303.9 333.5,-293.34 326.72,-295.08"/>
-<text text-anchor="middle" x="320.45" y="-270.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_a22 -->
-<g id="node13" class="node">
-<title>Phi_a22</title>
-<ellipse fill="lightyellow" stroke="black" cx="241" cy="-250" rx="27" ry="18"/>
-<text text-anchor="middle" x="241" y="-246.3" font-family="Times,serif" font-size="14.00">φ_a</text>
-</g>
-<!-- Phi_a22&#45;&gt;Con_6 -->
-<g id="edge15" class="edge">
-<title>Phi_a22&#45;&gt;Con_6</title>
-<path fill="none" stroke="black" d="M245.36,-267.95C247.39,-275.86 249.86,-285.46 252.14,-294.31"/>
-<polygon fill="black" stroke="black" points="248.8,-295.4 254.68,-304.21 255.58,-293.65 248.8,-295.4"/>
-<text text-anchor="middle" x="242.36" y="-270.55" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_a22&#45;&gt;Con_12 -->
-<g id="edge14" class="edge">
-<title>Phi_a22&#45;&gt;Con_12</title>
-<path fill="none" stroke="black" d="M229.02,-266.54C222.02,-275.6 213.06,-287.21 205.21,-297.39"/>
-<polygon fill="black" stroke="black" points="202.29,-295.45 198.95,-305.51 207.83,-299.73 202.29,-295.45"/>
-<text text-anchor="middle" x="226.02" y="-269.14" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_a22&#45;&gt;Region21 -->
-<g id="edge13" class="edge">
-<title>Phi_a22&#45;&gt;Region21</title>
-<path fill="none" stroke="black" stroke-dasharray="1,5" d="M268.12,-250C270.58,-250 273.04,-250 275.5,-250"/>
-<polygon fill="black" stroke="black" points="275.61,-253.5 285.61,-250 275.61,-246.5 275.61,-253.5"/>
-<text text-anchor="middle" x="271.12" y="-243.6" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Phi_b23 -->
-<g id="node14" class="node">
-<title>Phi_b23</title>
-<ellipse fill="lightyellow" stroke="black" cx="133" cy="-250" rx="27.1" ry="18"/>
-<text text-anchor="middle" x="133" y="-246.3" font-family="Times,serif" font-size="14.00">φ_b</text>
-</g>
-<!-- Phi_b23&#45;&gt;Con_7 -->
-<g id="edge18" class="edge">
-<title>Phi_b23&#45;&gt;Con_7</title>
-<path fill="none" stroke="black" d="M128.64,-267.95C126.61,-275.86 124.14,-285.46 121.86,-294.31"/>
-<polygon fill="black" stroke="black" points="118.42,-293.65 119.32,-304.21 125.2,-295.4 118.42,-293.65"/>
-<text text-anchor="middle" x="125.64" y="-270.55" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Phi_b23&#45;&gt;Phi_b20 -->
-<g id="edge17" class="edge">
-<title>Phi_b23&#45;&gt;Phi_b20</title>
-<path fill="none" stroke="black" d="M116.07,-264.17C102.58,-274.66 83.49,-289.51 68.2,-301.4"/>
-<polygon fill="black" stroke="black" points="65.9,-298.75 60.16,-307.65 70.2,-304.28 65.9,-298.75"/>
-<text text-anchor="middle" x="113.07" y="-266.77" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Phi_b23&#45;&gt;Region21 -->
-<g id="edge16" class="edge">
-<title>Phi_b23&#45;&gt;Region21</title>
-<path fill="none" stroke="black" stroke-dasharray="1,5" d="M152.84,-237.61C179.31,-222.7 227.54,-201.16 268,-214 275.99,-216.54 283.81,-220.83 290.83,-225.58"/>
-<polygon fill="black" stroke="black" points="289.11,-228.66 299.24,-231.75 293.25,-223.01 289.11,-228.66"/>
-<text text-anchor="middle" x="149.84" y="-231.21" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Add24 -->
-<g id="node15" class="node">
-<title>Add24</title>
-<ellipse fill="none" stroke="black" cx="241" cy="-178" rx="27" ry="18"/>
-<text text-anchor="middle" x="241" y="-174.3" font-family="Times,serif" font-size="14.00">+</text>
-</g>
-<!-- Add24&#45;&gt;Phi_a22 -->
-<g id="edge20" class="edge">
-<title>Add24&#45;&gt;Phi_a22</title>
-<path fill="none" stroke="black" d="M241,-196.3C241,-204.02 241,-213.29 241,-221.89"/>
-<polygon fill="black" stroke="black" points="237.5,-221.9 241,-231.9 244.5,-221.9 237.5,-221.9"/>
-<text text-anchor="middle" x="238" y="-198.9" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
-</g>
-<!-- Add24&#45;&gt;Phi_b23 -->
-<g id="edge19" class="edge">
-<title>Add24&#45;&gt;Phi_b23</title>
-<path fill="none" stroke="black" d="M222.19,-191.19C205.1,-202.27 179.69,-218.74 160.36,-231.27"/>
-<polygon fill="black" stroke="black" points="158.45,-228.34 151.96,-236.71 162.25,-234.21 158.45,-228.34"/>
-<text text-anchor="middle" x="219.19" y="-193.79" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-<!-- Return25&#45;&gt;Region21 -->
-<g id="edge21" class="edge">
-<title>Return25&#45;&gt;Region21</title>
-<path fill="none" stroke="red" d="M277.67,-124.13C285.71,-148.44 300.52,-193.18 310.06,-221.99"/>
-<polygon fill="red" stroke="red" points="306.85,-223.42 313.31,-231.81 313.49,-221.22 306.85,-223.42"/>
-<text text-anchor="middle" x="274.67" y="-126.73" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
-</g>
-<!-- Return25&#45;&gt;Add24 -->
-<g id="edge22" class="edge">
-<title>Return25&#45;&gt;Add24</title>
-<path fill="none" stroke="black" d="M264.34,-124.3C260.76,-132.39 256.42,-142.19 252.46,-151.13"/>
-<polygon fill="black" stroke="black" points="249.21,-149.82 248.36,-160.38 255.61,-152.65 249.21,-149.82"/>
-<text text-anchor="middle" x="261.34" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
-</g>
-</g>
-</svg>
+<svg aria-label="Compiler graph" width="1086" height="1042" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1086 1042" style="font-family: sans-serif;"><style>
+ html, body { height:100%; margin:0; font-family:sans-serif; }
+ .viewer { height:100%; display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
+ .source { padding:8px; border-bottom:1px solid #ccc; }
+ #program { width:min(600px,80vw); vertical-align:middle; }
+ #status { margin-top:4px; }
+ #graph { min-height:0; overflow:hidden; position:relative; background:#fafbfc; }
+ #elk { width:100%; height:100%; }
+ #graph svg { display:block; }
+ .tools { display:flex; flex-wrap:wrap; align-items:center; gap:14px; margin-top:8px; font-size:12px; }
+ .hint { color:#616c78; }
+ .ctrl { color:#b63838; } .mem { color:#2867b2; } .data { color:#536477; }
+ .edge { fill:none; stroke-width:1.5; }
+ .edge.CTRL { stroke-width:2; }
+ .edge.ASSOC { stroke-dasharray:4 4; }
+ .edge.PARSER { stroke-dasharray:5 4; }
+ .parser rect { fill:#f6f0ff; stroke:#7956a5; stroke-width:1.5; stroke-dasharray:5 4; }
+ .edge.selected { stroke-width:3.5; }
+ .edge.bundle { stroke-width:4; }
+ .edge.bundle.selected { stroke-width:6; }
+ .edge-hit { fill:none; stroke:transparent; stroke-width:12; vector-effect:non-scaling-stroke; pointer-events:stroke; cursor:pointer; }
+ .edge-jump { fill:transparent; pointer-events:all; cursor:pointer; }
+ .node { cursor:pointer; }
+ .box { stroke:#758191; stroke-width:1; }
+ .node.held .box { stroke-dasharray:5 3; }
+ .node.near .box { stroke:#c18221; stroke-width:2; }
+ .node.focus .box { stroke:#9c4900; stroke-width:3; }
+ .node.selected .box { stroke:#1569b9; stroke-width:3; }
+ .node.folded .box { stroke-width:4; }
+ .node.folding .box { fill:#f4ccd7; }
+ .fold-tag { font-size:9px; font-weight:700; fill:#963751; }
+ .peep-area { fill:#fff3d9; fill-opacity:.8; stroke:#c18221; stroke-width:2; pointer-events:none; }
+ .node.peep-edit .box { stroke:#9c4900; stroke-width:3; }
+ .node.error .box { stroke:#b42318; stroke-width:4; }
+ #event.error { color:#b42318; font-weight:600; white-space:pre-wrap; overflow-wrap:anywhere; }
+ .peep-ghosts { pointer-events:none; }
+ .region-box { stroke:#9da9b8; stroke-width:1.5; }
+ .fold-btn { cursor:pointer; }
+ .fold-btn rect { fill:white; stroke:#596674; }
+ .fold-btn text { font-size:14px; fill:#152330; }
+ .fold-btn:focus rect { stroke:#1569b9; stroke-width:2; }
+ .shortcut { cursor:pointer; }
+ .shortcut path { fill:none; stroke-width:1.5; }
+ .shortcut rect { fill:#fff8ec; stroke:#b63838; stroke-dasharray:3 2; }
+ .shortcut text { font-size:11px; fill:#783030; }
+ .shortcut.selected rect, .shortcut:focus rect { stroke-width:2.5; }
+ .label { font-size:12px; fill:#152330; font-weight:600; }
+ .node-id { font-size:10px; fill:#596674; font-weight:400; }
+ .type { font-size:11px; fill:#455768; }
+ .port { stroke:#536477; stroke-width:1; }
+ .row { stroke:#b6afcf; stroke-width:1; }
+ .bind { font-size:12px; fill:#152330; }
+ .slot { font-size:10px; fill:#364352; paint-order:stroke; stroke:#fafbfc; stroke-width:3; }
+ #detail { position:absolute; top:8px; right:8px; margin:0; padding:12px; max-width:320px;
+ max-height:45%; overflow:auto; white-space:pre-wrap; overflow-wrap:anywhere;
+ background:#fffffff2; border:1px solid #bac5d0; border-radius:4px; font-size:12px; }
+ .controls { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:6px; padding:6px; }
+ .button { color:white; background:black; font-size:20px; min-width:30px; }
+ .button:disabled { background:grey; }
+ .count { font-size:20px; min-width:35px; text-align:center; }
+ #N { width:6ch; }
+ #scrub { width:clamp(120px,35vw,600px); }
+ </style><defs><marker id="arrow-CTRL" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#b63838"/></marker><marker id="arrow-DATA" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#536477"/></marker><marker id="arrow-MEM" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#2867b2"/></marker><marker id="arrow-ASSOC" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#9396a3"/></marker><marker id="arrow-PARSER" viewBox="0 -4 8 8" refX="8" refY="0" markerWidth="7" markerHeight="7" orient="auto-start-reverse"><path d="M0,-4L8,0L0,4Z" fill="#7956a5"/></marker></defs><rect width="100%" height="100%" fill="rgb(250, 251, 252)"/><g><g class="regions" style="opacity: 1;"><g class="region" transform="translate(24,171)"><rect class="region-box" rx="8" width="608" height="664" fill="#f2f7ef"/></g><g class="region" transform="translate(227,358)"><rect class="region-box" rx="8" width="360" height="250" fill="#f2f7ef"/></g></g><rect class="peep-area" rx="36" style="opacity: 0;"/><g class="edges"><path class="edge CTRL" id="e3i0" d="M206,941 C206,965 543,968 543,992" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#3[0] → #25 · CTRL</title></path><path class="edge CTRL" id="e8i0" d="M116,118 L116,205" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#8[0] → #1 · CTRL</title></path><path class="edge DATA" id="e8i1" d="M236,118 L236,138 L196,138 L196,205" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#8[1] → #4 · DATA</title></path><path class="edge CTRL" id="e13i0" d="M96,305 L96,315 L319,315 L319,392" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#13[0] → #5 · CTRL</title></path><path class="edge DATA" id="e13i1" d="M236,118 L236,138 L399,138 L399,392" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#13[1] → #4 · DATA</title></path><path class="edge CTRL" id="e19i1" d="M299,492 L299,502 L363,502 L363,540" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#19[1] → #10 · CTRL</title></path><path class="edge CTRL" id="e19i2" d="M419,492 L419,502 L393,502 L393,540" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#19[2] → #11 · CTRL</title></path><path class="edge DATA" id="e20i1" d="M394,118 L394,128 L495,128 L495,540" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#20[1] → #17 · DATA</title></path><path class="edge DATA" id="e20i2" d="M546,118 L546,128 L535,128 L535,540" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#20[2] → #18 · DATA</title></path><path class="edge CTRL" id="e21i1" d="M363,596 L363,623 L186,623 L186,663" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#21[1] → #19 · CTRL</title></path><path class="edge CTRL" id="e21i2" d="M216,305 L216,663" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#21[2] → #9 · CTRL</title></path><path class="edge DATA" id="e22i1" d="M698,118 L698,128 L597,128 L597,633 L318,633 L318,663" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#22[1] → #12 · DATA</title></path><path class="edge DATA" id="e22i2" d="M850,118 L850,138 L608,138 L608,643 L358,643 L358,663" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#22[2] → #6 · DATA</title></path><path class="edge DATA" id="e23i1" d="M515,596 L515,623 L470,623 L470,663" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#23[1] → #20 · DATA</title></path><path class="edge DATA" id="e23i2" d="M1002,118 L1002,148 L619,148 L619,653 L510,653 L510,663" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#23[2] → #7 · DATA</title></path><path class="edge DATA" id="e24i1" d="M490,719 L490,729 L308,729 L308,767" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#24[1] → #23 · DATA</title></path><path class="edge DATA" id="e24i2" d="M338,719 L338,767" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#24[2] → #22 · DATA</title></path><path class="edge CTRL" id="e25i0" d="M186,719 L186,888" stroke="#b63838" marker-start="url(#arrow-CTRL)" style="opacity: 1;"><title>#25[0] → #21 · CTRL</title></path><path class="edge DATA" id="e25i1" d="M308,823 L308,850 L226,850 L226,888" stroke="#536477" marker-start="url(#arrow-DATA)" style="opacity: 1;"><title>#25[1] → #24 · DATA</title></path></g><g class="edge-hits"/><g class="parser" style="opacity: 1;"/><g class="nodes"><g class="node" id="n1" data-id="1" transform="translate(56,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>$ctrl</tspan><tspan class="node-id">  #1/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#1 $ctrl
+Projection 0 of #2
+Type not computed
+
+[0] → #2 CTRL</title></g><g class="node" id="n2" data-id="2" transform="translate(56,24)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>Start</tspan><tspan class="node-id">  #2</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#2 Start
+Type not computed
+
+</title></g><g class="node" id="n3" data-id="3" transform="translate(507,992)" style="opacity: 1;"><path class="box" d="M0,0H72V26H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="36" y="17"><tspan>Stop</tspan><tspan class="node-id">  #3</tspan></text><text class="type" text-anchor="middle" y="35" x="36"/><title>#3 Stop
+Type not computed
+
+[0] → #25 CTRL</title><circle class="port" cx="36" cy="0" r="3" fill="#536477"/><text class="slot" x="36" y="-7" text-anchor="middle">0</text></g><g class="node" id="n4" data-id="4" transform="translate(176,68)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>arg</tspan><tspan class="node-id">  #4/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#4 arg
+Projection 1 of #2
+Type not computed
+
+[0] → #2 DATA</title></g><g class="node" id="n5" data-id="5" transform="translate(36,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>True</tspan><tspan class="node-id">  #5/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#5 True
+Projection 0 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n6" data-id="6" transform="translate(790,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#0</tspan><tspan class="node-id">  #6</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#6 #0
+Type not computed
+
+</title></g><g class="node" id="n7" data-id="7" transform="translate(942,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#1</tspan><tspan class="node-id">  #7</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#7 #1
+Type not computed
+
+</title></g><g class="node" id="n8" data-id="8" transform="translate(36,211)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#8 If
+Type not computed
+
+[0] → #1 CTRL
+[1] → #4 DATA</title><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><circle class="port" cx="160" cy="-3" r="3" fill="#536477"/><text class="slot" x="80" y="-10" text-anchor="middle">0</text><text class="slot" x="160" y="-10" text-anchor="middle">1</text></g><g class="node" id="n9" data-id="9" transform="translate(156,255)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>False</tspan><tspan class="node-id">  #9/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#9 False
+Projection 1 of #8
+Type not computed
+
+[0] → #8 CTRL</title></g><g class="node" id="n10" data-id="10" transform="translate(239,442)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>True</tspan><tspan class="node-id">  #10/0</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#10 True
+Projection 0 of #13
+Type not computed
+
+[0] → #13 CTRL</title></g><g class="node" id="n11" data-id="11" transform="translate(359,442)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>False</tspan><tspan class="node-id">  #11/1</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#11 False
+Projection 1 of #13
+Type not computed
+
+[0] → #13 CTRL</title></g><g class="node" id="n12" data-id="12" transform="translate(638,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #12</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#12 #2
+Type not computed
+
+</title></g><g class="node" id="n13" data-id="13" transform="translate(239,398)" style="opacity: 1;"><path class="box" d="M0,0H240V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="120" y="18"><tspan>If</tspan><tspan class="node-id">  #13</tspan></text><text class="type" text-anchor="middle" y="35" x="120"/><title>#13 If
+Type not computed
+
+[0] → #5 CTRL
+[1] → #4 DATA</title><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><circle class="port" cx="160" cy="-3" r="3" fill="#536477"/><text class="slot" x="80" y="-10" text-anchor="middle">0</text><text class="slot" x="160" y="-10" text-anchor="middle">1</text></g><g class="node" id="n17" data-id="17" transform="translate(334,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#2</tspan><tspan class="node-id">  #17</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#17 #2
+Type not computed
+
+</title></g><g class="node" id="n18" data-id="18" transform="translate(486,68)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>#3</tspan><tspan class="node-id">  #18</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#18 #3
+Type not computed
+
+</title></g><g class="node" id="n19" data-id="19" transform="translate(303,546)" style="opacity: 1;"><path class="box" d="M12,0H108L120,44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Region</tspan><tspan class="node-id">  #19</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#19 Region
+Type not computed
+
+[0] → — DATA
+[1] → #10 CTRL
+[2] → #11 CTRL</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n20" data-id="20" transform="translate(455,546)" style="opacity: 1;"><path class="box" d="M12,0H108L120,22L108,44H12L0,22Z" fill="#f5e4fa"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>φ_b</tspan><tspan class="node-id">  #20</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#20 φ_b
+Type not computed
+
+[0] → #19 ASSOC
+[1] → #17 DATA
+[2] → #18 DATA</title><circle class="port" cx="-3" cy="22" r="3" fill="#536477"/><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><path class="reg" fill="none" stroke="#b63838" d="M-3,22H-18m4,-3l-4,3l4,3"><title>[0] → #19</title></path><text class="slot" x="-10" y="15" text-anchor="middle">0</text><text class="slot" x="40" y="-10" text-anchor="middle">1</text><text class="slot" x="80" y="-10" text-anchor="middle">2</text></g><g class="node" id="n21" data-id="21" transform="translate(126,669)" style="opacity: 1;"><path class="box" d="M12,0H108L120,44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Region</tspan><tspan class="node-id">  #21</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#21 Region
+Type not computed
+
+[0] → — DATA
+[1] → #19 CTRL
+[2] → #9 CTRL</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n22" data-id="22" transform="translate(278,669)" style="opacity: 1;"><path class="box" d="M12,0H108L120,22L108,44H12L0,22Z" fill="#f5e4fa"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>φ_a</tspan><tspan class="node-id">  #22</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#22 φ_a
+Type not computed
+
+[0] → #21 ASSOC
+[1] → #12 DATA
+[2] → #6 DATA</title><circle class="port" cx="-3" cy="22" r="3" fill="#536477"/><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><path class="reg" fill="none" stroke="#b63838" d="M-3,22H-18m4,-3l-4,3l4,3"><title>[0] → #21</title></path><text class="slot" x="-10" y="15" text-anchor="middle">0</text><text class="slot" x="40" y="-10" text-anchor="middle">1</text><text class="slot" x="80" y="-10" text-anchor="middle">2</text></g><g class="node" id="n23" data-id="23" transform="translate(430,669)" style="opacity: 1;"><path class="box" d="M12,0H108L120,22L108,44H12L0,22Z" fill="#f5e4fa"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>φ_b</tspan><tspan class="node-id">  #23</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#23 φ_b
+Type not computed
+
+[0] → #21 ASSOC
+[1] → #20 DATA
+[2] → #7 DATA</title><circle class="port" cx="-3" cy="22" r="3" fill="#536477"/><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><path class="reg" fill="none" stroke="#b63838" d="M-3,22H-18m4,-3l-4,3l4,3"><title>[0] → #21</title></path><text class="slot" x="-10" y="15" text-anchor="middle">0</text><text class="slot" x="40" y="-10" text-anchor="middle">1</text><text class="slot" x="80" y="-10" text-anchor="middle">2</text></g><g class="node" id="n24" data-id="24" transform="translate(248,773)" style="opacity: 1;"><path class="box" d="M14,0H106Q120,0 120,14V30Q120,44 106,44H14Q0,44 0,30V14Q0,0 14,0Z" fill="#edf3f7"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>+</tspan><tspan class="node-id">  #24</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#24 +
+Type not computed
+
+[0] → — DATA
+[1] → #23 DATA
+[2] → #22 DATA</title><circle class="port" cx="30" cy="-3" r="3" fill="white"/><circle class="port" cx="60" cy="-3" r="3" fill="#536477"/><circle class="port" cx="90" cy="-3" r="3" fill="#536477"/><text class="slot" x="30" y="-10" text-anchor="middle">0</text><text class="slot" x="60" y="-10" text-anchor="middle">1</text><text class="slot" x="90" y="-10" text-anchor="middle">2</text></g><g class="node" id="n25" data-id="25" transform="translate(146,894)" style="opacity: 1;"><path class="box" d="M0,0H120V44H0Z" fill="#fff1c4"/><text class="label" text-anchor="middle" x="60" y="18"><tspan>Return</tspan><tspan class="node-id">  #25</tspan></text><text class="type" text-anchor="middle" y="35" x="60"/><title>#25 Return
+Type not computed
+
+[0] → #21 CTRL
+[1] → #24 DATA</title><circle class="port" cx="40" cy="-3" r="3" fill="#536477"/><circle class="port" cx="80" cy="-3" r="3" fill="#536477"/><text class="slot" x="40" y="-10" text-anchor="middle">0</text><text class="slot" x="80" y="-10" text-anchor="middle">1</text></g></g><g class="region-heads" style="opacity: 1;"><g class="region-head" transform="translate(24,171)"><text class="label" x="26" y="17"><tspan>If</tspan><tspan class="node-id">  #8</tspan></text><title>If · 12 nodes</title><g class="fold-btn" role="button" tabindex="0" transform="translate(4,4)" aria-label="Fold region #8"><rect width="16" height="16" rx="2"/><text x="8" y="12" text-anchor="middle">−</text><title>Fold region</title></g></g><g class="region-head" transform="translate(227,358)"><text class="label" x="26" y="17"><tspan>If</tspan><tspan class="node-id">  #13</tspan></text><title>If · 5 nodes</title><g class="fold-btn" role="button" tabindex="0" transform="translate(4,4)" aria-label="Fold region #13"><rect width="16" height="16" rx="2"/><text x="8" y="12" text-anchor="middle">−</text><title>Fold region</title></g></g></g><g class="shortcuts" style="opacity: 1;"/><g class="peep-ghosts" pointer-events="none"/></g></svg>
diff --git a/chapter06/docs/Makefile b/chapter06/docs/Makefile
index 12659b8f..6fa0f057 100644
--- a/chapter06/docs/Makefile
+++ b/chapter06/docs/Makefile
@@ -1,12 +1 @@
-GV := $(wildcard *.gv)
-SVG := $(patsubst %.gv,%.svg,$(GV))
-
-.PHONY: all
-all: $(SVG)
-
-%.svg: %.gv
- dot -Tsvg $< > $@
-
-.PHONY: clean
-clean:
- @rm -f $(SVG)
+include ../../graph/docs.mk