summaryrefslogtreecommitdiff
path: root/chapter10/docs/example2b.svg
diff options
context:
space:
mode:
authorDibyendu Majumdar <dibyendumajumdar@users.noreply.github.com>2024-04-29 00:11:36 +0100
committerGitHub <noreply@github.com>2024-04-28 16:11:36 -0700
commite31c37890a86aedfb209cf543baf05b1b60a27d2 (patch)
tree5c1151adb45e839a8f4b0f7cc918bf49771e52f1 /chapter10/docs/example2b.svg
parent17f9d743c06170f20773863bd1eca4f25ef41490 (diff)
downloadSimple-e31c37890a86aedfb209cf543baf05b1b60a27d2.tar.gz
Simple-e31c37890a86aedfb209cf543baf05b1b60a27d2.zip
Ch10update (#75)
* Store-after-Store peep * Load-after-Store peephole * Fix graph viz mem edge color bug * Scalar replace loop carried dependence * #67 Dead Not node hanging around - if we add a Not in the upcast then add it to the IterPeeps worklist to ensure it gets cleaned up. We don't see the Not node in the parser hence we cannot do a peep on it there. * #67 Update visuals. Add description of Store-Store and Store-Load peeps. Add examples. * #67 Undo the change that wasn't supposed to be committed! * #67 Update description of the Store-Store and Store-Load peepholes --------- Co-authored-by: Cliff Click <cliffc@acm.org>
Diffstat (limited to 'chapter10/docs/example2b.svg')
-rw-r--r--chapter10/docs/example2b.svg189
1 files changed, 189 insertions, 0 deletions
diff --git a/chapter10/docs/example2b.svg b/chapter10/docs/example2b.svg
new file mode 100644
index 00000000..1ecf4de7
--- /dev/null
+++ b/chapter10/docs/example2b.svg
@@ -0,0 +1,189 @@
+<?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: chapter10 Pages: 1 -->
+<svg width="369pt" height="464pt"
+ viewBox="0.00 0.00 368.60 464.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 460)">
+<title>chapter10</title>
+<polygon fill="white" stroke="transparent" points="-4,4 -4,-460 364.6,-460 364.6,4 -4,4"/>
+<g id="clust1" class="cluster">
+<title>cluster_Nodes</title>
+<polygon fill="none" stroke="black" points="8,-8 8,-448 346,-448 346,-8 8,-8"/>
+</g>
+<!-- Start2 -->
+<g id="node1" class="node">
+<title>Start2</title>
+<polygon fill="yellow" stroke="transparent" points="152,-411 152,-436 277,-436 277,-411 152,-411"/>
+<polygon fill="none" stroke="black" points="152,-411 152,-436 277,-436 277,-411 152,-411"/>
+<text text-anchor="start" x="196" y="-419.8" font-family="Times,serif" font-size="14.00">Start</text>
+<polygon fill="none" stroke="black" points="152,-380 152,-411 277,-411 277,-380 152,-380"/>
+<polygon fill="yellow" stroke="transparent" points="157,-385 157,-406 197,-406 197,-385 157,-385"/>
+<polygon fill="none" stroke="black" points="157,-385 157,-406 197,-406 197,-385 157,-385"/>
+<text text-anchor="start" x="160" y="-391.8" font-family="Times,serif" font-size="14.00">$ctrl</text>
+<polygon fill="none" stroke="black" points="197,-385 197,-406 222,-406 222,-385 197,-385"/>
+<text text-anchor="start" x="200" y="-391.8" font-family="Times,serif" font-size="14.00">$2</text>
+<polygon fill="none" stroke="black" points="222,-385 222,-406 247,-406 247,-385 222,-385"/>
+<text text-anchor="start" x="225" y="-391.8" font-family="Times,serif" font-size="14.00">$3</text>
+<polygon fill="none" stroke="black" points="247,-385 247,-406 272,-406 272,-385 247,-385"/>
+<text text-anchor="start" x="250" y="-391.8" font-family="Times,serif" font-size="14.00">$4</text>
+</g>
+<!-- Stop3 -->
+<g id="node2" class="node">
+<title>Stop3</title>
+<polygon fill="yellow" stroke="black" points="139,-52 85,-52 85,-16 139,-16 139,-52"/>
+<text text-anchor="middle" x="112" y="-30.3" font-family="Times,serif" font-size="14.00">Stop</text>
+</g>
+<!-- Return19 -->
+<g id="node9" class="node">
+<title>Return19</title>
+<polygon fill="yellow" stroke="black" points="145,-124 79,-124 79,-88 145,-88 145,-124"/>
+<text text-anchor="middle" x="112" y="-102.3" font-family="Times,serif" font-size="14.00">Return</text>
+</g>
+<!-- Stop3&#45;&gt;Return19 -->
+<g id="edge1" class="edge">
+<title>Stop3&#45;&gt;Return19</title>
+<path fill="none" stroke="red" d="M112,-52.3C112,-60.02 112,-69.29 112,-77.89"/>
+<polygon fill="red" stroke="red" points="108.5,-77.9 112,-87.9 115.5,-77.9 108.5,-77.9"/>
+<text text-anchor="middle" x="109" y="-54.9" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
+</g>
+<!-- new10 -->
+<g id="node3" class="node">
+<title>new10</title>
+<ellipse fill="none" stroke="black" cx="177" cy="-322" rx="49.29" ry="18"/>
+<text text-anchor="middle" x="177" y="-318.3" font-family="Times,serif" font-size="14.00">new Bar</text>
+</g>
+<!-- new10&#45;&gt;Start2 -->
+<g id="edge2" class="edge">
+<title>new10&#45;&gt;Start2:p0</title>
+<path fill="none" stroke="green" d="M177,-340.09C177,-349.55 177,-361.77 177,-373.69"/>
+<polygon fill="green" stroke="green" points="173.5,-374 177,-384 180.5,-374 173.5,-374"/>
+<text text-anchor="middle" x="174" y="-342.69" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
+</g>
+<!-- Con_11 -->
+<g id="node4" class="node">
+<title>Con_11</title>
+<ellipse fill="none" stroke="black" cx="291" cy="-322" rx="27" ry="18"/>
+<text text-anchor="middle" x="291" y="-318.3" font-family="Times,serif" font-size="14.00">#0</text>
+</g>
+<!-- Store13 -->
+<g id="node5" class="node">
+<title>Store13</title>
+<ellipse fill="none" stroke="black" cx="266" cy="-250" rx="30.59" ry="18"/>
+<text text-anchor="middle" x="266" y="-246.3" font-family="Times,serif" font-size="14.00">.b =</text>
+</g>
+<!-- Store13&#45;&gt;Start2 -->
+<g id="edge3" class="edge">
+<title>Store13&#45;&gt;Start2:p3</title>
+<path fill="none" stroke="blue" d="M259.43,-267.92C251.04,-290.96 237.36,-333.9 235.27,-373.91"/>
+<polygon fill="blue" stroke="blue" points="231.77,-373.91 235,-384 238.77,-374.1 231.77,-373.91"/>
+<text text-anchor="middle" x="256.43" y="-270.52" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
+</g>
+<!-- Store13&#45;&gt;new10 -->
+<g id="edge4" class="edge">
+<title>Store13&#45;&gt;new10</title>
+<path fill="none" stroke="black" d="M248.42,-264.83C235.97,-274.62 219.01,-287.96 204.75,-299.17"/>
+<polygon fill="black" stroke="black" points="202.41,-296.56 196.72,-305.49 206.74,-302.06 202.41,-296.56"/>
+<text text-anchor="middle" x="245.42" y="-267.43" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
+</g>
+<!-- Store13&#45;&gt;Con_11 -->
+<g id="edge5" class="edge">
+<title>Store13&#45;&gt;Con_11</title>
+<path fill="none" stroke="black" d="M272.05,-267.95C274.91,-275.94 278.38,-285.67 281.57,-294.6"/>
+<polygon fill="black" stroke="black" points="278.34,-295.97 285,-304.21 284.94,-293.62 278.34,-295.97"/>
+<text text-anchor="middle" x="269.05" y="-270.55" font-family="Helvetica,sans-Serif" font-size="8.00">3</text>
+</g>
+<!-- Con_16 -->
+<g id="node6" class="node">
+<title>Con_16</title>
+<ellipse fill="none" stroke="black" cx="83" cy="-322" rx="27" ry="18"/>
+<text text-anchor="middle" x="83" y="-318.3" font-family="Times,serif" font-size="14.00">#2</text>
+</g>
+<!-- Store17 -->
+<g id="node7" class="node">
+<title>Store17</title>
+<ellipse fill="none" stroke="black" cx="74" cy="-250" rx="29.8" ry="18"/>
+<text text-anchor="middle" x="74" y="-246.3" font-family="Times,serif" font-size="14.00">.a =</text>
+</g>
+<!-- Store17&#45;&gt;Start2 -->
+<g id="edge6" class="edge">
+<title>Store17&#45;&gt;Start2:p2</title>
+<path fill="none" stroke="blue" d="M61.5,-266.67C47.91,-285.72 30.23,-318.07 47,-340 90.02,-396.26 197.33,-318.14 208.12,-373.87"/>
+<polygon fill="blue" stroke="blue" points="204.65,-374.34 209,-384 211.62,-373.74 204.65,-374.34"/>
+<text text-anchor="middle" x="58.5" y="-269.27" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
+</g>
+<!-- Store17&#45;&gt;new10 -->
+<g id="edge7" class="edge">
+<title>Store17&#45;&gt;new10</title>
+<path fill="none" stroke="black" d="M93.37,-264.17C108.16,-274.22 128.83,-288.27 145.92,-299.88"/>
+<polygon fill="black" stroke="black" points="144.25,-302.97 154.49,-305.7 148.18,-297.18 144.25,-302.97"/>
+<text text-anchor="middle" x="90.37" y="-266.77" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
+</g>
+<!-- Store17&#45;&gt;Con_16 -->
+<g id="edge8" class="edge">
+<title>Store17&#45;&gt;Con_16</title>
+<path fill="none" stroke="black" d="M76.22,-268.3C77.22,-276.02 78.41,-285.29 79.51,-293.89"/>
+<polygon fill="black" stroke="black" points="76.05,-294.42 80.8,-303.9 83,-293.53 76.05,-294.42"/>
+<text text-anchor="middle" x="73.22" y="-270.9" font-family="Helvetica,sans-Serif" font-size="8.00">3</text>
+</g>
+<!-- Load18 -->
+<g id="node8" class="node">
+<title>Load18</title>
+<ellipse fill="none" stroke="black" cx="112" cy="-178" rx="27" ry="18"/>
+<text text-anchor="middle" x="112" y="-174.3" font-family="Times,serif" font-size="14.00">.a</text>
+</g>
+<!-- Load18&#45;&gt;new10 -->
+<g id="edge10" class="edge">
+<title>Load18&#45;&gt;new10</title>
+<path fill="none" stroke="black" d="M119.58,-195.57C130.78,-220.02 151.82,-266 165.09,-294.98"/>
+<polygon fill="black" stroke="black" points="161.92,-296.46 169.26,-304.1 168.28,-293.55 161.92,-296.46"/>
+<text text-anchor="middle" x="116.58" y="-198.17" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
+</g>
+<!-- Load18&#45;&gt;Store17 -->
+<g id="edge9" class="edge">
+<title>Load18&#45;&gt;Store17</title>
+<path fill="none" stroke="blue" d="M103.19,-195.24C98.65,-203.6 93.01,-213.98 87.9,-223.39"/>
+<polygon fill="blue" stroke="blue" points="84.72,-221.91 83.03,-232.37 90.88,-225.25 84.72,-221.91"/>
+<text text-anchor="middle" x="100.19" y="-197.84" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
+</g>
+<!-- Return19&#45;&gt;Start2 -->
+<g id="edge11" class="edge">
+<title>Return19&#45;&gt;Start2:p0</title>
+<path fill="none" stroke="red" d="M78.92,-118.71C54.82,-129.48 25.06,-148.19 17,-177"/>
+<path fill="none" stroke="red" d="M17,-179C-2.42,-248.44 -5.52,-281.77 37,-340 66.51,-380.41 90.13,-391.98 133.12,-394.44"/>
+<polygon fill="red" stroke="red" points="133.09,-397.94 143.22,-394.85 133.37,-390.94 133.09,-397.94"/>
+<text text-anchor="middle" x="75.92" y="-112.31" font-family="Helvetica,sans-Serif" font-size="8.00">0</text>
+</g>
+<!-- Return19&#45;&gt;Start2 -->
+<g id="edge15" class="edge">
+<title>Return19&#45;&gt;Start2:p4</title>
+<path fill="none" stroke="blue" d="M337,-179C373.1,-264.02 373.34,-375.99 294.56,-392.84"/>
+<polygon fill="blue" stroke="blue" points="293.9,-389.4 284.56,-394.41 294.99,-396.32 293.9,-389.4"/>
+<text text-anchor="middle" x="334" y="-172.6" font-family="Helvetica,sans-Serif" font-size="8.00">4</text>
+</g>
+<!-- Return19&#45;&gt;Store13 -->
+<g id="edge14" class="edge">
+<title>Return19&#45;&gt;Store13</title>
+<path fill="none" stroke="blue" d="M145.2,-111.29C204,-119.77 321.73,-141.04 337,-177"/>
+<path fill="none" stroke="blue" d="M337,-179C346.91,-202.35 322.21,-221.91 299.27,-234.36"/>
+<polygon fill="blue" stroke="blue" points="297.63,-231.27 290.32,-238.94 300.82,-237.5 297.63,-231.27"/>
+<text text-anchor="middle" x="148.2" y="-104.89" font-family="Helvetica,sans-Serif" font-size="8.00">3</text>
+</g>
+<!-- Return19&#45;&gt;Store17 -->
+<g id="edge13" class="edge">
+<title>Return19&#45;&gt;Store17</title>
+<path fill="none" stroke="blue" d="M17,-179C11.2,-199.75 28.07,-218.41 44.94,-231.23"/>
+<polygon fill="blue" stroke="blue" points="42.94,-234.1 53.12,-237.04 46.99,-228.4 42.94,-234.1"/>
+<text text-anchor="middle" x="14" y="-172.6" font-family="Helvetica,sans-Serif" font-size="8.00">2</text>
+</g>
+<!-- Return19&#45;&gt;Load18 -->
+<g id="edge12" class="edge">
+<title>Return19&#45;&gt;Load18</title>
+<path fill="none" stroke="black" d="M112,-124.3C112,-132.02 112,-141.29 112,-149.89"/>
+<polygon fill="black" stroke="black" points="108.5,-149.9 112,-159.9 115.5,-149.9 108.5,-149.9"/>
+<text text-anchor="middle" x="109" y="-126.9" font-family="Helvetica,sans-Serif" font-size="8.00">1</text>
+</g>
+</g>
+</svg>