diff options
Diffstat (limited to '075array-equal.subx')
-rw-r--r-- | 075array-equal.subx | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/075array-equal.subx b/075array-equal.subx index 7f5109f9..d6dec878 100644 --- a/075array-equal.subx +++ b/075array-equal.subx @@ -5,24 +5,6 @@ # . op subop mod rm32 base index scale r32 # . 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 -Entry: - # initialize heap - # . Heap = new-segment(64KB) - # . . push args - 68/push Heap/imm32 - 68/push 0x10000/imm32/64KB - # . . call - e8/call new-segment/disp32 - # . . discard args - 81 0/subop/add 3/mod/direct 4/rm32/esp . . . . . 8/imm32 # add to esp - - e8/call run-tests/disp32 # 'run-tests' is a function created automatically by SubX. It calls all functions that start with 'test-'. -$array-equal-main:end: - # syscall(exit, Num-test-failures) - 8b/copy 0/mod/indirect 5/rm32/.disp32 . . 3/r32/ebx Num-test-failures/disp32 # copy *Num-test-failures to ebx - b8/copy-to-eax 1/imm32/exit - cd/syscall 0x80/imm8 - array-equal?: # a : (address array int), b : (address array int) -> eax : boolean # pseudocode: # lena = a->length @@ -618,12 +600,4 @@ test-check-array-equal: 5d/pop-to-ebp c3/return -== data - -Heap: - # curr - 0/imm32 - # limit - 0/imm32 - # . . vim:nowrap:textwidth=0 |