about summary refs log tree commit diff stats
path: root/apps/random.subx
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2020-06-10 23:09:30 -0700
committerKartik Agaram <vc@akkartik.com>2020-06-10 23:09:30 -0700
commit7dac9ade153d736b7a183d073d83b7a17b22b4cc (patch)
treef19ba4be87306ae53caa0ba8c61e5202899cee48 /apps/random.subx
parent72d893b6b1c0dcaea5c4a38dd6fd83fd0569dd79 (diff)
downloadmu-7dac9ade153d736b7a183d073d83b7a17b22b4cc.tar.gz
6507 - use syscall names everywhere
Diffstat (limited to 'apps/random.subx')
-rw-r--r--apps/random.subx9
1 files changed, 3 insertions, 6 deletions
diff --git a/apps/random.subx b/apps/random.subx
index 70eaffa2..3cc1caa2 100644
--- a/apps/random.subx
+++ b/apps/random.subx
@@ -14,8 +14,7 @@ Entry:
     bb/copy-to-ebx  Filename/imm32
     b9/copy-to-ecx  0/imm32/rdonly
     ba/copy-to-edx  0x180/imm32/fixed-perms
-    b8/copy-to-eax  5/imm32/open
-    cd/syscall  0x80/imm8
+    e8/call  syscall_open/disp32
     # . stream = eax
     89/copy                         3/mod/direct    6/rm32/esi    .           .             .           0/r32/eax   .               .                 # copy eax to esi
 
@@ -25,8 +24,7 @@ $loop:
     89/copy                         3/mod/direct    3/rm32/ebx    .           .             .           6/r32/esi   .               .                 # copy esi to ebx
     b9/copy-to-ecx  N/imm32
     ba/copy-to-edx  4/imm32/size
-    b8/copy-to-eax  3/imm32/read
-    cd/syscall  0x80/imm8
+    e8/call  syscall_read/disp32
 
     # print-int32-buffered(Stdout, *N)
     # . . push args
@@ -48,8 +46,7 @@ $loop:
 
     # syscall(exit, 0)
     bb/copy-to-ebx  0/imm32
-    b8/copy-to-eax  1/imm32/exit
-    cd/syscall  0x80/imm8
+    e8/call  syscall_exit/disp32
 
 == data 0x0a000000