This commit is contained in:
Kartik Agaram 2018-11-30 10:35:03 -08:00
parent dc70e29c20
commit 2b7ba2a56a
1 changed files with 4 additions and 4 deletions

View File

@ -3,8 +3,8 @@
# except that we support numbers of multiple digits.
#
# To run (from the subx directory):
# $ ./subx translate *.subx apps/crenshaw2-1.subx -o crenshaw2-1
# $ echo '1a' |./subx run apps/crenshaw2-1
# $ ./subx translate *.subx apps/crenshaw2-1b.subx -o crenshaw2-1b
# $ echo '1a' |./subx run apps/crenshaw2-1b
# Expected output:
# # syscall(exit, 1a)
# bb/copy-to-EBX 3/imm32
@ -12,14 +12,14 @@
# cd/syscall 0x80/imm8
#
# To run the generated output:
# $ echo '1a' |./subx run apps/crenshaw2-1 > z1.subx
# $ echo '1a' |./subx run apps/crenshaw2-1b > z1.subx
# $ ./subx translate z1.subx -o z1
# $ ./subx run z1
# $ echo $?
# 26 # 0x1a in decimal
#
# Stdin must contain just a single hex digit. Other input will print an error:
# $ echo 'xyz' |./subx run apps/crenshaw2-1
# $ echo 'xyz' |./subx run apps/crenshaw2-1b
# Error: integer expected
#
# Names in this file sometimes follow Crenshaw's original rather than my usual