docs: Update state diagram

master
Sean McBride 4 years ago
parent 815546852c
commit 23b7f04a8a

@ -1,15 +1,15 @@
# The double dollar is needed to prevent expansion of $2 in the awk program
OS := $(shell awk -F= '/^NAME/{print $$2}' /etc/os-release)
states.svg: states.dot
dot -Tsvg states.dot > states.svg
clean:
rm -f states.svg
.PHONY: graphviz
graphviz.install:
echo ${OS}
ifeq (${OS},"Ubuntu")
sudo apt install graphviz
endif
states.svg: states.dot
dot -Tsvg states.dot > states.svg
clean:
rm -f states.svg

@ -1,8 +1,8 @@
digraph {
Uninitialized -> Initialized
Initialized -> {Runnable Error}
Runnable -> Running
Running -> {Blocked Runnable Returned Error}
{Runnable Running_User Preempted} -> Running_Kernel
Running_Kernel -> {Blocked Error Preempted Returned Running_User}
Returned -> Complete
Blocked -> Runnable
}

@ -4,115 +4,145 @@
<!-- Generated by graphviz version 2.43.0 (0)
-->
<!-- Title: %3 Pages: 1 -->
<svg width="319pt" height="404pt"
viewBox="0.00 0.00 318.84 404.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<svg width="632pt" height="404pt"
viewBox="0.00 0.00 631.84 404.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 400)">
<title>%3</title>
<polygon fill="white" stroke="transparent" points="-4,4 -4,-400 314.84,-400 314.84,4 -4,4"/>
<polygon fill="white" stroke="transparent" points="-4,4 -4,-400 627.84,-400 627.84,4 -4,4"/>
<!-- Uninitialized -->
<g id="node1" class="node">
<title>Uninitialized</title>
<ellipse fill="none" stroke="black" cx="207.45" cy="-378" rx="70.39" ry="18"/>
<text text-anchor="middle" x="207.45" y="-374.3" font-family="Times,serif" font-size="14.00">Uninitialized</text>
<ellipse fill="none" stroke="black" cx="371.45" cy="-378" rx="70.39" ry="18"/>
<text text-anchor="middle" x="371.45" y="-374.3" font-family="Times,serif" font-size="14.00">Uninitialized</text>
</g>
<!-- Initialized -->
<g id="node2" class="node">
<title>Initialized</title>
<ellipse fill="none" stroke="black" cx="207.45" cy="-306" rx="57.39" ry="18"/>
<text text-anchor="middle" x="207.45" y="-302.3" font-family="Times,serif" font-size="14.00">Initialized</text>
<ellipse fill="none" stroke="black" cx="371.45" cy="-306" rx="57.39" ry="18"/>
<text text-anchor="middle" x="371.45" y="-302.3" font-family="Times,serif" font-size="14.00">Initialized</text>
</g>
<!-- Uninitialized&#45;&gt;Initialized -->
<g id="edge1" class="edge">
<title>Uninitialized&#45;&gt;Initialized</title>
<path fill="none" stroke="black" d="M207.45,-359.7C207.45,-351.98 207.45,-342.71 207.45,-334.11"/>
<polygon fill="black" stroke="black" points="210.95,-334.1 207.45,-324.1 203.95,-334.1 210.95,-334.1"/>
<path fill="none" stroke="black" d="M371.45,-359.7C371.45,-351.98 371.45,-342.71 371.45,-334.11"/>
<polygon fill="black" stroke="black" points="374.95,-334.1 371.45,-324.1 367.95,-334.1 374.95,-334.1"/>
</g>
<!-- Runnable -->
<g id="node3" class="node">
<title>Runnable</title>
<ellipse fill="none" stroke="black" cx="166.45" cy="-234" rx="54.69" ry="18"/>
<text text-anchor="middle" x="166.45" y="-230.3" font-family="Times,serif" font-size="14.00">Runnable</text>
<ellipse fill="none" stroke="black" cx="315.45" cy="-234" rx="54.69" ry="18"/>
<text text-anchor="middle" x="315.45" y="-230.3" font-family="Times,serif" font-size="14.00">Runnable</text>
</g>
<!-- Initialized&#45;&gt;Runnable -->
<g id="edge2" class="edge">
<title>Initialized&#45;&gt;Runnable</title>
<path fill="none" stroke="black" d="M197.52,-288.05C192.69,-279.8 186.77,-269.7 181.4,-260.54"/>
<polygon fill="black" stroke="black" points="184.35,-258.65 176.28,-251.79 178.31,-262.19 184.35,-258.65"/>
<path fill="none" stroke="black" d="M358.17,-288.41C351.27,-279.78 342.7,-269.06 335.04,-259.5"/>
<polygon fill="black" stroke="black" points="337.6,-257.09 328.62,-251.47 332.14,-261.47 337.6,-257.09"/>
</g>
<!-- Error -->
<g id="node4" class="node">
<title>Error</title>
<ellipse fill="none" stroke="black" cx="274.45" cy="-90" rx="36.29" ry="18"/>
<text text-anchor="middle" x="274.45" y="-86.3" font-family="Times,serif" font-size="14.00">Error</text>
<ellipse fill="none" stroke="black" cx="587.45" cy="-90" rx="36.29" ry="18"/>
<text text-anchor="middle" x="587.45" y="-86.3" font-family="Times,serif" font-size="14.00">Error</text>
</g>
<!-- Initialized&#45;&gt;Error -->
<g id="edge3" class="edge">
<title>Initialized&#45;&gt;Error</title>
<path fill="none" stroke="black" d="M215.53,-288.06C220.26,-277.78 226.12,-264.3 230.45,-252 246.68,-205.83 260.65,-150.5 268.27,-118.19"/>
<polygon fill="black" stroke="black" points="271.75,-118.7 270.61,-108.17 264.93,-117.11 271.75,-118.7"/>
<path fill="none" stroke="black" d="M388.04,-288.56C426.34,-250.62 520.98,-156.85 564.67,-113.56"/>
<polygon fill="black" stroke="black" points="567.33,-115.86 571.97,-106.33 562.4,-110.89 567.33,-115.86"/>
</g>
<!-- Running -->
<g id="node5" class="node">
<title>Running</title>
<ellipse fill="none" stroke="black" cx="166.45" cy="-162" rx="50.09" ry="18"/>
<text text-anchor="middle" x="166.45" y="-158.3" font-family="Times,serif" font-size="14.00">Running</text>
<!-- Running_Kernel -->
<g id="node7" class="node">
<title>Running_Kernel</title>
<ellipse fill="none" stroke="black" cx="315.45" cy="-162" rx="84.49" ry="18"/>
<text text-anchor="middle" x="315.45" y="-158.3" font-family="Times,serif" font-size="14.00">Running_Kernel</text>
</g>
<!-- Runnable&#45;&gt;Running -->
<!-- Runnable&#45;&gt;Running_Kernel -->
<g id="edge4" class="edge">
<title>Runnable&#45;&gt;Running</title>
<path fill="none" stroke="black" d="M160.57,-216.05C159.75,-208.35 159.51,-199.03 159.84,-190.36"/>
<polygon fill="black" stroke="black" points="163.34,-190.49 160.53,-180.28 156.36,-190.01 163.34,-190.49"/>
<title>Runnable&#45;&gt;Running_Kernel</title>
<path fill="none" stroke="black" d="M315.45,-215.7C315.45,-207.98 315.45,-198.71 315.45,-190.11"/>
<polygon fill="black" stroke="black" points="318.95,-190.1 315.45,-180.1 311.95,-190.1 318.95,-190.1"/>
</g>
<!-- Running_User -->
<g id="node5" class="node">
<title>Running_User</title>
<ellipse fill="none" stroke="black" cx="315.45" cy="-90" rx="76.89" ry="18"/>
<text text-anchor="middle" x="315.45" y="-86.3" font-family="Times,serif" font-size="14.00">Running_User</text>
</g>
<!-- Running&#45;&gt;Runnable -->
<!-- Running_User&#45;&gt;Running_Kernel -->
<g id="edge5" class="edge">
<title>Running&#45;&gt;Runnable</title>
<path fill="none" stroke="black" d="M172.36,-180.28C173.16,-188.03 173.39,-197.36 173.04,-206.01"/>
<polygon fill="black" stroke="black" points="169.54,-205.83 172.32,-216.05 176.52,-206.33 169.54,-205.83"/>
<title>Running_User&#45;&gt;Running_Kernel</title>
<path fill="none" stroke="black" d="M321.34,-108.1C322.15,-115.79 322.38,-125.05 322.05,-133.67"/>
<polygon fill="black" stroke="black" points="318.55,-133.48 321.36,-143.7 325.54,-133.96 318.55,-133.48"/>
</g>
<!-- Preempted -->
<g id="node6" class="node">
<title>Preempted</title>
<ellipse fill="none" stroke="black" cx="471.45" cy="-90" rx="61.99" ry="18"/>
<text text-anchor="middle" x="471.45" y="-86.3" font-family="Times,serif" font-size="14.00">Preempted</text>
</g>
<!-- Running&#45;&gt;Error -->
<!-- Preempted&#45;&gt;Running_Kernel -->
<g id="edge6" class="edge">
<title>Running&#45;&gt;Error</title>
<path fill="none" stroke="black" d="M189.61,-145.98C205.66,-135.58 227.17,-121.64 244.51,-110.4"/>
<polygon fill="black" stroke="black" points="246.66,-113.18 253.15,-104.8 242.85,-107.31 246.66,-113.18"/>
<title>Preempted&#45;&gt;Running_Kernel</title>
<path fill="none" stroke="black" d="M443.44,-106.11C421.31,-116.62 390.07,-130.7 363.94,-141.97"/>
<polygon fill="black" stroke="black" points="362.38,-138.83 354.57,-145.98 365.14,-145.26 362.38,-138.83"/>
</g>
<!-- Running_Kernel&#45;&gt;Error -->
<g id="edge7" class="edge">
<title>Running_Kernel&#45;&gt;Error</title>
<path fill="none" stroke="black" d="M375.28,-149.28C421.39,-139.71 486.5,-125.02 542.45,-108 545.05,-107.21 547.73,-106.34 550.41,-105.43"/>
<polygon fill="black" stroke="black" points="551.79,-108.66 560.04,-102.01 549.44,-102.06 551.79,-108.66"/>
</g>
<!-- Running_Kernel&#45;&gt;Running_User -->
<g id="edge8" class="edge">
<title>Running_Kernel&#45;&gt;Running_User</title>
<path fill="none" stroke="black" d="M309.53,-143.7C308.73,-135.98 308.51,-126.71 308.85,-118.11"/>
<polygon fill="black" stroke="black" points="312.34,-118.32 309.55,-108.1 305.36,-117.84 312.34,-118.32"/>
</g>
<!-- Running_Kernel&#45;&gt;Preempted -->
<g id="edge9" class="edge">
<title>Running_Kernel&#45;&gt;Preempted</title>
<path fill="none" stroke="black" d="M345.08,-145.12C368.01,-134.27 400,-119.88 426.11,-108.67"/>
<polygon fill="black" stroke="black" points="427.61,-111.84 435.44,-104.7 424.87,-105.4 427.61,-111.84"/>
</g>
<!-- Blocked -->
<g id="node6" class="node">
<g id="node8" class="node">
<title>Blocked</title>
<ellipse fill="none" stroke="black" cx="47.45" cy="-90" rx="47.39" ry="18"/>
<text text-anchor="middle" x="47.45" y="-86.3" font-family="Times,serif" font-size="14.00">Blocked</text>
</g>
<!-- Running&#45;&gt;Blocked -->
<g id="edge7" class="edge">
<title>Running&#45;&gt;Blocked</title>
<path fill="none" stroke="black" d="M141.5,-146.33C123.85,-135.94 99.99,-121.91 80.72,-110.57"/>
<polygon fill="black" stroke="black" points="82.35,-107.47 71.95,-105.42 78.8,-113.5 82.35,-107.47"/>
<!-- Running_Kernel&#45;&gt;Blocked -->
<g id="edge10" class="edge">
<title>Running_Kernel&#45;&gt;Blocked</title>
<path fill="none" stroke="black" d="M260.79,-148.13C217.86,-137.82 156.65,-122.72 103.45,-108 99.91,-107.02 96.25,-105.98 92.59,-104.91"/>
<polygon fill="black" stroke="black" points="93.5,-101.53 82.92,-102.06 91.52,-108.25 93.5,-101.53"/>
</g>
<!-- Returned -->
<g id="node7" class="node">
<g id="node9" class="node">
<title>Returned</title>
<ellipse fill="none" stroke="black" cx="166.45" cy="-90" rx="53.89" ry="18"/>
<text text-anchor="middle" x="166.45" y="-86.3" font-family="Times,serif" font-size="14.00">Returned</text>
</g>
<!-- Running&#45;&gt;Returned -->
<g id="edge8" class="edge">
<title>Running&#45;&gt;Returned</title>
<path fill="none" stroke="black" d="M166.45,-143.7C166.45,-135.98 166.45,-126.71 166.45,-118.11"/>
<polygon fill="black" stroke="black" points="169.95,-118.1 166.45,-108.1 162.95,-118.1 169.95,-118.1"/>
<!-- Running_Kernel&#45;&gt;Returned -->
<g id="edge11" class="edge">
<title>Running_Kernel&#45;&gt;Returned</title>
<path fill="none" stroke="black" d="M282.01,-145.29C259.43,-134.69 229.55,-120.65 205.82,-109.5"/>
<polygon fill="black" stroke="black" points="207.27,-106.31 196.73,-105.23 204.3,-112.65 207.27,-106.31"/>
</g>
<!-- Blocked&#45;&gt;Runnable -->
<g id="edge10" class="edge">
<g id="edge13" class="edge">
<title>Blocked&#45;&gt;Runnable</title>
<path fill="none" stroke="black" d="M57.15,-107.95C68.17,-126.54 87.26,-156.8 107.45,-180 116.88,-190.84 128.43,-201.66 138.8,-210.66"/>
<polygon fill="black" stroke="black" points="136.57,-213.35 146.45,-217.16 141.1,-208.02 136.57,-213.35"/>
<path fill="none" stroke="black" d="M74.17,-105.16C122.41,-130.72 224.08,-184.59 278.77,-213.57"/>
<polygon fill="black" stroke="black" points="277.3,-216.75 287.77,-218.34 280.58,-210.56 277.3,-216.75"/>
</g>
<!-- Complete -->
<g id="node8" class="node">
<g id="node10" class="node">
<title>Complete</title>
<ellipse fill="none" stroke="black" cx="166.45" cy="-18" rx="55.49" ry="18"/>
<text text-anchor="middle" x="166.45" y="-14.3" font-family="Times,serif" font-size="14.00">Complete</text>
</g>
<!-- Returned&#45;&gt;Complete -->
<g id="edge9" class="edge">
<g id="edge12" class="edge">
<title>Returned&#45;&gt;Complete</title>
<path fill="none" stroke="black" d="M166.45,-71.7C166.45,-63.98 166.45,-54.71 166.45,-46.11"/>
<polygon fill="black" stroke="black" points="169.95,-46.1 166.45,-36.1 162.95,-46.1 169.95,-46.1"/>

Before

Width:  |  Height:  |  Size: 5.8 KiB

After

Width:  |  Height:  |  Size: 7.4 KiB

Loading…
Cancel
Save