diff options
author | Kartik Agaram <vc@akkartik.com> | 2020-01-27 00:39:46 -0800 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2020-01-27 00:39:46 -0800 |
commit | 2104d1a75b76dbffc0b15a96c98d94e7a16594e8 (patch) | |
tree | 2a839b86e76431a9bbe4bf155f7411171a26d7f8 /html/082slurp.subx.html | |
parent | 71eb22a5bf94f5fa0a3c95212450e3c6a1a6a990 (diff) | |
download | mu-2104d1a75b76dbffc0b15a96c98d94e7a16594e8.tar.gz |
5925
Diffstat (limited to 'html/082slurp.subx.html')
-rw-r--r-- | html/082slurp.subx.html | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/html/082slurp.subx.html b/html/082slurp.subx.html index 9491c189..b182707c 100644 --- a/html/082slurp.subx.html +++ b/html/082slurp.subx.html @@ -64,7 +64,7 @@ if ('onhashchange' in window) { <span id="L5" class="LineNr"> 5 </span> <span id="L6" class="LineNr"> 6 </span><span class="subxComment"># read all bytes from 'f' and store them into 's'</span> <span id="L7" class="LineNr"> 7 </span><span class="subxComment"># abort if 's' is too small</span> -<span id="L8" class="LineNr"> 8 </span><span class="subxFunction">slurp</span>: <span class="subxComment"># f : (addr buffered-file), s : (addr stream byte)</span> +<span id="L8" class="LineNr"> 8 </span><span class="subxFunction">slurp</span>: <span class="subxComment"># f: (addr buffered-file), s: (addr stream byte)</span> <span id="L9" class="LineNr"> 9 </span> <span class="subxComment"># pseudocode:</span> <span id="L10" class="LineNr"> 10 </span> <span class="subxComment"># while true</span> <span id="L11" class="LineNr"> 11 </span> <span class="subxComment"># if (s->write >= s->length) abort</span> @@ -122,7 +122,7 @@ if ('onhashchange' in window) { <span id="L63" class="LineNr"> 63 </span> 3d/compare-eax-and 0/imm32 <span id="L64" class="LineNr"> 64 </span> 74/jump-if-= $slurp:end/disp8 <span id="L65" class="LineNr"> 65 </span><span class="Constant">$slurp:from-stream</span>: -<span id="L66" class="LineNr"> 66 </span> <span class="subxComment"># var c/eax : byte = f->data[f->read]</span> +<span id="L66" class="LineNr"> 66 </span> <span class="subxComment"># var c/eax: byte = f->data[f->read]</span> <span id="L67" class="LineNr"> 67 </span> 31/xor 3/mod/direct 0/rm32/eax <span class="Normal"> . </span> <span class="Normal"> . </span> <span class="Normal"> . </span> 0/r32/eax <span class="Normal"> . </span> <span class="Normal"> . </span> <span class="subxComment"># clear eax</span> <span id="L68" class="LineNr"> 68 </span> 8a/copy-byte 1/mod/*+disp8 4/rm32/sib 6/base/esi 1/index/ecx <span class="Normal"> . </span> 0/r32/AL 0x10/disp8 <span class="Normal"> . </span> <span class="subxComment"># copy byte at *(esi+ecx+16) to AL</span> <span id="L69" class="LineNr"> 69 </span> <span class="subxComment"># s->data[s->write] = c</span> |