about summary refs log tree commit diff stats
path: root/html/058stream-equal.subx.html
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2020-01-27 00:39:46 -0800
committerKartik Agaram <vc@akkartik.com>2020-01-27 00:39:46 -0800
commit2104d1a75b76dbffc0b15a96c98d94e7a16594e8 (patch)
tree2a839b86e76431a9bbe4bf155f7411171a26d7f8 /html/058stream-equal.subx.html
parent71eb22a5bf94f5fa0a3c95212450e3c6a1a6a990 (diff)
downloadmu-2104d1a75b76dbffc0b15a96c98d94e7a16594e8.tar.gz
5925
Diffstat (limited to 'html/058stream-equal.subx.html')
-rw-r--r--html/058stream-equal.subx.html28
1 files changed, 14 insertions, 14 deletions
diff --git a/html/058stream-equal.subx.html b/html/058stream-equal.subx.html
index 231f300e..2d38ddef 100644
--- a/html/058stream-equal.subx.html
+++ b/html/058stream-equal.subx.html
@@ -65,7 +65,7 @@ if ('onhashchange' in window) {
 <span id="L6" class="LineNr">  6 </span><span class="subxS1Comment"># . 1-3 bytes   3 bits              2 bits          3 bits        3 bits      3 bits        2 bits      2 bits      0/1/2/4 bytes   0/1/2/4 bytes</span>
 <span id="L7" class="LineNr">  7 </span>
 <span id="L8" class="LineNr">  8 </span><span class="subxComment"># compare all the data in a stream (ignoring the read pointer)</span>
-<span id="L9" class="LineNr">  9 </span><span class="subxFunction">stream-data-equal?</span>:  <span class="subxComment"># f : (addr stream byte), s : (addr array byte) -&gt; eax : boolean</span>
+<span id="L9" class="LineNr">  9 </span><span class="subxFunction">stream-data-equal?</span>:  <span class="subxComment"># f: (addr stream byte), s: (addr array byte) -&gt; eax: boolean</span>
 <span id="L10" class="LineNr"> 10 </span>    <span class="subxS1Comment"># . prologue</span>
 <span id="L11" class="LineNr"> 11 </span>    55/push-ebp
 <span id="L12" class="LineNr"> 12 </span>    89/copy                         3/mod/direct    5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          4/r32/esp  <span class="Normal"> . </span>             <span class="Normal"> . </span>                <span class="subxComment"># copy esp to ebp</span>
@@ -78,9 +78,9 @@ if ('onhashchange' in window) {
 <span id="L19" class="LineNr"> 19 </span>    8b/copy                         1/mod/*+disp8   5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          6/r32/esi   8/disp8        <span class="Normal"> . </span>                <span class="subxComment"># copy *(ebp+8) to esi</span>
 <span id="L20" class="LineNr"> 20 </span>    <span class="subxComment"># eax = f-&gt;write</span>
 <span id="L21" class="LineNr"> 21 </span>    8b/copy                         0/mod/indirect  6/rm32/esi   <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"># copy *esi to eax</span>
-<span id="L22" class="LineNr"> 22 </span>    <span class="subxComment"># var maxf/edx : (addr byte) = &amp;f-&gt;data[f-&gt;write]</span>
+<span id="L22" class="LineNr"> 22 </span>    <span class="subxComment"># var maxf/edx: (addr byte) = &amp;f-&gt;data[f-&gt;write]</span>
 <span id="L23" class="LineNr"> 23 </span>    8d/copy-address                 1/mod/*+disp8   4/rm32/sib    6/base/esi  0/index/eax  <span class="Normal"> . </span>          2/r32/edx   0xc/disp8      <span class="Normal"> . </span>                <span class="subxComment"># copy esi+eax+12 to edx</span>
-<span id="L24" class="LineNr"> 24 </span>    <span class="subxComment"># var currf/esi : (addr byte) = f-&gt;data</span>
+<span id="L24" class="LineNr"> 24 </span>    <span class="subxComment"># var currf/esi: (addr byte) = f-&gt;data</span>
 <span id="L25" class="LineNr"> 25 </span>    81          0/subop/add         3/mod/direct    6/rm32/esi   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>         <span class="Normal"> . </span>         <span class="Normal"> . </span>              0xc/imm32         <span class="subxComment"># add to esi</span>
 <span id="L26" class="LineNr"> 26 </span>    <span class="subxComment"># edi = s</span>
 <span id="L27" class="LineNr"> 27 </span>    8b/copy                         1/mod/*+disp8   5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          7/r32/edi   0xc/disp8      <span class="Normal"> . </span>                <span class="subxComment"># copy *(ebp+12) to edi</span>
@@ -88,11 +88,11 @@ if ('onhashchange' in window) {
 <span id="L29" class="LineNr"> 29 </span>    <span class="subxComment"># if (f-&gt;write != s-&gt;length) return false</span>
 <span id="L30" class="LineNr"> 30 </span>    39/compare                      0/mod/indirect  7/rm32/edi   <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"># compare *edi and eax</span>
 <span id="L31" class="LineNr"> 31 </span>    75/jump-if-!=  $stream-data-equal?:false/disp8
-<span id="L32" class="LineNr"> 32 </span>    <span class="subxComment"># var currs/edi : (addr byte) = s-&gt;data</span>
+<span id="L32" class="LineNr"> 32 </span>    <span class="subxComment"># var currs/edi: (addr byte) = s-&gt;data</span>
 <span id="L33" class="LineNr"> 33 </span>    81          0/subop/add         3/mod/direct    7/rm32/edi   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>         <span class="Normal"> . </span>         <span class="Normal"> . </span>              4/imm32           <span class="subxComment"># add to edi</span>
-<span id="L34" class="LineNr"> 34 </span>    <span class="subxComment"># var eax : byte = 0</span>
+<span id="L34" class="LineNr"> 34 </span>    <span class="subxComment"># var eax: byte = 0</span>
 <span id="L35" class="LineNr"> 35 </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="L36" class="LineNr"> 36 </span>    <span class="subxComment"># var ecx : byte = 0</span>
+<span id="L36" class="LineNr"> 36 </span>    <span class="subxComment"># var ecx: byte = 0</span>
 <span id="L37" class="LineNr"> 37 </span>    31/xor                          3/mod/direct    1/rm32/ecx   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          1/r32/ecx  <span class="Normal"> . </span>             <span class="Normal"> . </span>                <span class="subxComment"># clear ecx</span>
 <span id="L38" class="LineNr"> 38 </span><span class="Constant">$stream-data-equal?:loop</span>:
 <span id="L39" class="LineNr"> 39 </span>    <span class="subxComment"># if (currf &gt;= maxf) return true</span>
@@ -250,7 +250,7 @@ if ('onhashchange' in window) {
 <span id="L191" class="LineNr">191 </span>    c3/return
 <span id="L192" class="LineNr">192 </span>
 <span id="L193" class="LineNr">193 </span><span class="subxComment"># helper for later tests</span>
-<span id="L194" class="LineNr">194 </span><span class="subxFunction">check-stream-equal</span>:  <span class="subxComment"># f : (addr stream byte), s : (addr array byte), msg : (addr array byte)</span>
+<span id="L194" class="LineNr">194 </span><span class="subxFunction">check-stream-equal</span>:  <span class="subxComment"># f: (addr stream byte), s: (addr array byte), msg: (addr array byte)</span>
 <span id="L195" class="LineNr">195 </span>    <span class="subxS1Comment"># . prologue</span>
 <span id="L196" class="LineNr">196 </span>    55/push-ebp
 <span id="L197" class="LineNr">197 </span>    89/copy                         3/mod/direct    5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          4/r32/esp  <span class="Normal"> . </span>             <span class="Normal"> . </span>                <span class="subxComment"># copy esp to ebp</span>
@@ -286,10 +286,10 @@ if ('onhashchange' in window) {
 <span id="L227" class="LineNr">227 </span><span class="subxComment"># on success, set f-&gt;read to after the next newline</span>
 <span id="L228" class="LineNr">228 </span><span class="subxComment"># on failure, leave f-&gt;read unmodified</span>
 <span id="L229" class="LineNr">229 </span><span class="subxComment"># this function is usually used only in tests, so we repeatedly write f-&gt;read</span>
-<span id="L230" class="LineNr">230 </span><span class="subxFunction">next-stream-line-equal?</span>:  <span class="subxComment"># f : (addr stream byte), s : (addr array byte) -&gt; eax : boolean</span>
+<span id="L230" class="LineNr">230 </span><span class="subxFunction">next-stream-line-equal?</span>:  <span class="subxComment"># f: (addr stream byte), s: (addr array byte) -&gt; eax: boolean</span>
 <span id="L231" class="LineNr">231 </span>    <span class="subxComment"># pseudocode:</span>
 <span id="L232" class="LineNr">232 </span>    <span class="subxComment">#   currf = f-&gt;read  # bound: f-&gt;write</span>
-<span id="L233" class="LineNr">233 </span>    <span class="subxComment">#   currs = 0  # bound : s-&gt;length</span>
+<span id="L233" class="LineNr">233 </span>    <span class="subxComment">#   currs = 0  # bound: s-&gt;length</span>
 <span id="L234" class="LineNr">234 </span>    <span class="subxComment">#   while true</span>
 <span id="L235" class="LineNr">235 </span>    <span class="subxComment">#     if currf &gt;= f-&gt;write</span>
 <span id="L236" class="LineNr">236 </span>    <span class="subxComment">#       return currs &gt;= s-&gt;length</span>
@@ -303,7 +303,7 @@ if ('onhashchange' in window) {
 <span id="L244" class="LineNr">244 </span>    <span class="subxComment">#</span>
 <span id="L245" class="LineNr">245 </span>    <span class="subxComment"># collapsing the two branches that can return true:</span>
 <span id="L246" class="LineNr">246 </span>    <span class="subxComment">#   currf = f-&gt;read  # bound: f-&gt;write</span>
-<span id="L247" class="LineNr">247 </span>    <span class="subxComment">#   currs = 0  # bound : s-&gt;length</span>
+<span id="L247" class="LineNr">247 </span>    <span class="subxComment">#   currs = 0  # bound: s-&gt;length</span>
 <span id="L248" class="LineNr">248 </span>    <span class="subxComment">#   while true</span>
 <span id="L249" class="LineNr">249 </span>    <span class="subxComment">#     if (currf &gt;= f-&gt;write) break</span>
 <span id="L250" class="LineNr">250 </span>    <span class="subxComment">#     if (f[currf] == '\n') break</span>
@@ -333,15 +333,15 @@ if ('onhashchange' in window) {
 <span id="L274" class="LineNr">274 </span>    57/push-edi
 <span id="L275" class="LineNr">275 </span>    <span class="subxComment"># esi = f</span>
 <span id="L276" class="LineNr">276 </span>    8b/copy                         1/mod/*+disp8   5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          6/r32/esi   8/disp8        <span class="Normal"> . </span>                <span class="subxComment"># copy *(ebp+8) to esi</span>
-<span id="L277" class="LineNr">277 </span>    <span class="subxComment"># var currf/ecx : int = f-&gt;read</span>
+<span id="L277" class="LineNr">277 </span>    <span class="subxComment"># var currf/ecx: int = f-&gt;read</span>
 <span id="L278" class="LineNr">278 </span>    8b/copy                         1/mod/*+disp8   6/rm32/esi   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          1/r32/ecx   4/disp8        <span class="Normal"> . </span>                <span class="subxComment"># copy *(esi+4) to ecx</span>
 <span id="L279" class="LineNr">279 </span>    <span class="subxComment"># edi = s</span>
 <span id="L280" class="LineNr">280 </span>    8b/copy                         1/mod/*+disp8   5/rm32/ebp   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          7/r32/edi   0xc/disp8      <span class="Normal"> . </span>                <span class="subxComment"># copy *(ebp+12) to edi</span>
-<span id="L281" class="LineNr">281 </span>    <span class="subxComment"># var currs/edx : int = 0</span>
+<span id="L281" class="LineNr">281 </span>    <span class="subxComment"># var currs/edx: int = 0</span>
 <span id="L282" class="LineNr">282 </span>    31/xor                          3/mod/direct    2/rm32/edx   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          2/r32/edx  <span class="Normal"> . </span>             <span class="Normal"> . </span>                <span class="subxComment"># clear edx</span>
-<span id="L283" class="LineNr">283 </span>    <span class="subxComment"># var c1/eax : byte = 0</span>
+<span id="L283" class="LineNr">283 </span>    <span class="subxComment"># var c1/eax: byte = 0</span>
 <span id="L284" class="LineNr">284 </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="L285" class="LineNr">285 </span>    <span class="subxComment"># var c2/ebx : byte = 0</span>
+<span id="L285" class="LineNr">285 </span>    <span class="subxComment"># var c2/ebx: byte = 0</span>
 <span id="L286" class="LineNr">286 </span>    31/xor                          3/mod/direct    3/rm32/ebx   <span class="Normal"> . </span>         <span class="Normal"> . </span>           <span class="Normal"> . </span>          3/r32/ebx  <span class="Normal"> . </span>             <span class="Normal"> . </span>                <span class="subxComment"># clear ebx</span>
 <span id="L287" class="LineNr">287 </span><span class="Constant">$next-stream-line-equal?:loop</span>:
 <span id="L288" class="LineNr">288 </span>    <span class="subxComment"># if (currf &gt;= f-&gt;write) break</span>