ack/mach/i86/libem/strhp.s
1991-09-02 15:46:16 +00:00

28 lines
334 B
ArmAsm

.sect .text; .sect .rom; .sect .data; .sect .bss
.sect .text
.define .strhp
.extern .reghp, .limhp, EHEAP, .trp
.strhp:
pop bx
pop ax
mov (.reghp),ax
cmp ax,(.limhp)
jb 1f
add ax,02000
and ax,~0777
push bx
push ax
call __brk
pop cx
pop bx
cmp ax,-1
je 2f
1:
mov (.limhp),cx
jmp bx
2:
mov ax,EHEAP
push bx
jmp .trp