diff options
-rw-r--r-- | 066write-int-hex.subx (renamed from 066print-int.subx) | 16 | ||||
-rw-r--r-- | 068error-byte.subx | 4 | ||||
-rw-r--r-- | 078emit-hex.subx | 4 | ||||
-rw-r--r-- | 091write-int.subx | 2 | ||||
-rwxr-xr-x | apps/assort | bin | 44392 -> 44396 bytes | |||
-rwxr-xr-x | apps/braces | bin | 46255 -> 46259 bytes | |||
-rwxr-xr-x | apps/calls | bin | 50902 -> 50906 bytes | |||
-rwxr-xr-x | apps/crenshaw2-1 | bin | 43733 -> 43737 bytes | |||
-rwxr-xr-x | apps/crenshaw2-1b | bin | 44280 -> 44284 bytes | |||
-rwxr-xr-x | apps/dquotes | bin | 48014 -> 48018 bytes | |||
-rwxr-xr-x | apps/factorial | bin | 42836 -> 42840 bytes | |||
-rwxr-xr-x | apps/hex | bin | 46572 -> 46576 bytes | |||
-rwxr-xr-x | apps/mu | bin | 341134 -> 341138 bytes | |||
-rwxr-xr-x | apps/pack | bin | 56971 -> 56975 bytes | |||
-rwxr-xr-x | apps/sigils | bin | 58624 -> 58628 bytes | |||
-rwxr-xr-x | apps/survey | bin | 54324 -> 54328 bytes | |||
-rwxr-xr-x | apps/tests | bin | 43164 -> 43168 bytes | |||
-rw-r--r-- | html/066write-int-hex.subx.html (renamed from html/066print-int.subx.html) | 0 |
18 files changed, 13 insertions, 13 deletions
diff --git a/066print-int.subx b/066write-int-hex.subx index cc604ce8..6746891e 100644 --- a/066print-int.subx +++ b/066write-int-hex.subx @@ -1,4 +1,4 @@ -# Print the (hex) textual representation of numbers. +# Write out the (hex) textual representation of numbers. == code # instruction effective address register displacement immediate @@ -90,7 +90,7 @@ test-append-byte-hex: c3/return # print the hex representation for the lowest byte of a number -print-byte-buffered: # f: (addr buffered-file), n: int +write-byte-hex-buffered: # f: (addr buffered-file), n: int # . prologue 55/push-ebp 89/copy 3/mod/direct 5/rm32/ebp . . . 4/r32/esp . . # copy esp to ebp @@ -123,7 +123,7 @@ print-byte-buffered: # f: (addr buffered-file), n: int e8/call write-byte-buffered/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp -$print-byte-buffered:end: +$write-byte-hex-buffered:end: # . restore registers 58/pop-to-eax # . epilogue @@ -131,8 +131,8 @@ $print-byte-buffered:end: 5d/pop-to-ebp c3/return -test-print-byte-buffered: - # - check that print-byte-buffered prints the hex textual representation +test-write-byte-hex-buffered: + # - check that write-byte-hex-buffered prints the hex textual representation # setup # . clear-stream(_test-stream) # . . push args @@ -148,12 +148,12 @@ test-print-byte-buffered: e8/call clear-stream/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 4/imm32 # add to esp - # print-byte-buffered(_test-buffered-file, 0xa) # exercises digit, non-digit as well as leading zero + # write-byte-hex-buffered(_test-buffered-file, 0xa) # exercises digit, non-digit as well as leading zero # . . push args 68/push 0xa/imm32 68/push _test-buffered-file/imm32 # . . call - e8/call print-byte-buffered/disp32 + e8/call write-byte-hex-buffered/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp # flush(_test-buffered-file) @@ -165,7 +165,7 @@ test-print-byte-buffered: 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 4/imm32 # add to esp # check-stream-equal(_test-stream, "0a", msg) # . . push args - 68/push "F - test-print-byte-buffered"/imm32 + 68/push "F - test-write-byte-hex-buffered"/imm32 68/push "0a"/imm32 68/push _test-stream/imm32 # . . call diff --git a/068error-byte.subx b/068error-byte.subx index 1d7729b5..1ce0a3d6 100644 --- a/068error-byte.subx +++ b/068error-byte.subx @@ -51,12 +51,12 @@ error-byte: # ed: (addr exit-descriptor), out: (addr buffered-file), msg: (addr e8/call write-buffered/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp - # print-byte-buffered(out, byte) + # write-byte-hex-buffered(out, byte) # . . push args ff 6/subop/push 1/mod/*+disp8 5/rm32/ebp . . . . 0x14/disp8 . # push *(ebp+20) ff 6/subop/push 1/mod/*+disp8 5/rm32/ebp . . . . 0xc/disp8 . # push *(ebp+12) # . . call - e8/call print-byte-buffered/disp32 + e8/call write-byte-hex-buffered/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp # write-buffered(out, Newline) diff --git a/078emit-hex.subx b/078emit-hex.subx index 075f8e4b..d8869956 100644 --- a/078emit-hex.subx +++ b/078emit-hex.subx @@ -26,12 +26,12 @@ $emit-hex:loop: # if (curr >= width) break 39/compare 3/mod/direct 1/rm32/ecx . . . 2/r32/edx . . # compare ecx with edx 7d/jump-if->= $emit-hex:end/disp8 - # print-byte-buffered(out, ebx) # only BL used + # write-byte-hex-buffered(out, ebx) # only BL used # . . push args 53/push-ebx 57/push-edi # . . call - e8/call print-byte-buffered/disp32 + e8/call write-byte-hex-buffered/disp32 # . . discard args 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp # write-byte-buffered(out, ' ') diff --git a/091write-int.subx b/091write-int.subx index 2b5b60a1..97e681c7 100644 --- a/091write-int.subx +++ b/091write-int.subx @@ -1,4 +1,4 @@ -# write-int: add a single int to a stream +# write-int: add (the binary representation of) a single int to a stream == code # instruction effective address register displacement immediate diff --git a/apps/assort b/apps/assort index 7d565a5a..ed5e532e 100755 --- a/apps/assort +++ b/apps/assort Binary files differdiff --git a/apps/braces b/apps/braces index b51d7c2a..710fb8a7 100755 --- a/apps/braces +++ b/apps/braces Binary files differdiff --git a/apps/calls b/apps/calls index 7c8d6328..18e07c13 100755 --- a/apps/calls +++ b/apps/calls Binary files differdiff --git a/apps/crenshaw2-1 b/apps/crenshaw2-1 index 104c787f..3c86c4cc 100755 --- a/apps/crenshaw2-1 +++ b/apps/crenshaw2-1 Binary files differdiff --git a/apps/crenshaw2-1b b/apps/crenshaw2-1b index ec4c777c..a9ca75d0 100755 --- a/apps/crenshaw2-1b +++ b/apps/crenshaw2-1b Binary files differdiff --git a/apps/dquotes b/apps/dquotes index 3a22d5d7..80b18682 100755 --- a/apps/dquotes +++ b/apps/dquotes Binary files differdiff --git a/apps/factorial b/apps/factorial index 34a2c970..4cd0d4e4 100755 --- a/apps/factorial +++ b/apps/factorial Binary files differdiff --git a/apps/hex b/apps/hex index 137c479b..e6f9e3f1 100755 --- a/apps/hex +++ b/apps/hex Binary files differdiff --git a/apps/mu b/apps/mu index 4710f635..c3144d0a 100755 --- a/apps/mu +++ b/apps/mu Binary files differdiff --git a/apps/pack b/apps/pack index bcd5af94..4ff31f99 100755 --- a/apps/pack +++ b/apps/pack Binary files differdiff --git a/apps/sigils b/apps/sigils index 48895ab3..798ede8b 100755 --- a/apps/sigils +++ b/apps/sigils Binary files differdiff --git a/apps/survey b/apps/survey index 1fdc091f..1aa149e5 100755 --- a/apps/survey +++ b/apps/survey Binary files differdiff --git a/apps/tests b/apps/tests index b4c445f2..9db94934 100755 --- a/apps/tests +++ b/apps/tests Binary files differdiff --git a/html/066print-int.subx.html b/html/066write-int-hex.subx.html index dac46129..dac46129 100644 --- a/html/066print-int.subx.html +++ b/html/066write-int-hex.subx.html |