diff options
author | Kartik Agaram <vc@akkartik.com> | 2021-11-09 09:23:31 -0800 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2021-11-09 09:23:31 -0800 |
commit | 3ff2fe607c2cb5690d201d3b83ddcc957e949b7a (patch) | |
tree | 2dd6019731bad313ecf0423d6063c9d0fa0bb77e /html/linux/apps/ex5.subx.html | |
parent | ef8fd8851a883eefd7bd55ffc31d6e00f67d50a8 (diff) | |
download | mu-3ff2fe607c2cb5690d201d3b83ddcc957e949b7a.tar.gz |
.
Diffstat (limited to 'html/linux/apps/ex5.subx.html')
-rw-r--r-- | html/linux/apps/ex5.subx.html | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/html/linux/apps/ex5.subx.html b/html/linux/apps/ex5.subx.html index 949e207c..d3e8282e 100644 --- a/html/linux/apps/ex5.subx.html +++ b/html/linux/apps/ex5.subx.html @@ -15,9 +15,9 @@ body { font-size:12pt; font-family: monospace; color: #000000; background-color: a { color:inherit; } * { font-size:12pt; font-size: 1em; } .subxComment { color: #005faf; } +.subxS1Comment { color: #0000af; } .subxS2Comment { color: #8a8a8a; } .LineNr { } -.subxS1Comment { color: #0000af; } .SpecialChar { color: #d70000; } .Normal { color: #000000; background-color: #ffffd7; padding-bottom: 1px; } --> @@ -58,8 +58,8 @@ if ('onhashchange' in window) { <span id="L1" class="LineNr"> 1 </span><span class="subxComment"># Read a character from stdin, save it to a local on the stack, write it to stdout.</span> <span id="L2" class="LineNr"> 2 </span><span class="subxComment">#</span> <span id="L3" class="LineNr"> 3 </span><span class="subxComment"># To run:</span> -<span id="L4" class="LineNr"> 4 </span><span class="subxComment"># $ bootstrap/bootstrap translate apps/ex5.subx -o ex5</span> -<span id="L5" class="LineNr"> 5 </span><span class="subxComment"># $ bootstrap/bootstrap run ex5</span> +<span id="L4" class="LineNr"> 4 </span><span class="subxComment"># $ ./translate_subx 000init.subx apps/ex5.subx</span> +<span id="L5" class="LineNr"> 5 </span><span class="subxComment"># $ ./a.elf</span> <span id="L6" class="LineNr"> 6 </span> <span id="L7" class="LineNr"> 7 </span>== code <span id="L8" class="LineNr"> 8 </span><span class="subxComment"># instruction effective address register displacement immediate</span> @@ -81,7 +81,7 @@ if ('onhashchange' in window) { <span id="L24" class="LineNr">24 </span> <span class="subxS1Comment"># . syscall</span> <span id="L25" class="LineNr">25 </span> e8/call <a href='../000init.subx.html#L23'>syscall_read</a>/disp32 <span id="L26" class="LineNr">26 </span> -<span id="L27" class="LineNr">27 </span> <span class="subxComment"># syscall(write, stdout, x, 1)</span> +<span id="L27" class="LineNr">27 </span> <span class="subxComment"># syscall_write(stdout, x, 1)</span> <span id="L28" class="LineNr">28 </span> <span class="subxS1Comment"># . fd = 1 (stdout)</span> <span id="L29" class="LineNr">29 </span> bb/copy-to-ebx 1/imm32 <span id="L30" class="LineNr">30 </span> <span class="subxS1Comment"># . data = x (location to read from)</span> |