4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <meta name="generator" content="AsciiDoc 8.6.9">
7 <link rel="stylesheet" href="./asciidoc.css" type="text/css">
8 <link rel="stylesheet" href="./pygments.css" type="text/css">
11 <script type="text/javascript" src="./asciidoc.js"></script>
12 <script type="text/javascript">
17 <link rel="stylesheet" href="./mlton.css" type="text/css">
19 <body class="article">
21 <div id="banner-home">
22 <a href="./Home">MLton 20180207</a>
30 <div class="sectionbody">
31 <div class="paragraph"><p><a href="ToSSA2">ToSSA2</a> is a translation pass from the <a href="SSA">SSA</a>
32 <a href="IntermediateLanguage">IntermediateLanguage</a> to the <a href="SSA2">SSA2</a> <a href="IntermediateLanguage">IntermediateLanguage</a>.</p></div>
36 <h2 id="_description">Description</h2>
37 <div class="sectionbody">
38 <div class="paragraph"><p>This pass is a simple conversion from a <a href="SSA">SSA</a> program into a
39 <a href="SSA2">SSA2</a> program.</p></div>
40 <div class="paragraph"><p>The only interesting portions of the translation are:</p></div>
41 <div class="ulist"><ul>
44 an <a href="SSA">SSA</a> <span class="monospaced">ref</span> type becomes an object with a single mutable field
49 <span class="monospaced">array</span>, <span class="monospaced">vector</span>, and <span class="monospaced">ref</span> are eliminated in favor of select and updates
54 <span class="monospaced">Case</span> transfers separate discrimination and constructor argument selects
61 <h2 id="_implementation">Implementation</h2>
62 <div class="sectionbody">
63 <div class="ulist"><ul>
66 <a href="https://github.com/MLton/mlton/blob/master/mlton/ssa/ssa-to-ssa2.sig"><span class="monospaced">ssa-to-ssa2.sig</span></a>
71 <a href="https://github.com/MLton/mlton/blob/master/mlton/ssa/ssa-to-ssa2.fun"><span class="monospaced">ssa-to-ssa2.fun</span></a>
78 <h2 id="_details_and_notes">Details and Notes</h2>
79 <div class="sectionbody">
80 <div class="paragraph"><p></p></div>
84 <div id="footnotes"><hr></div>
86 <div id="footer-text">
88 <div id="footer-badges">