Files
open-simh.simtools/crossassemblers/macro11/tests/2.11BSD/m11/debug.m11
Olaf Seibert 0e54092d45 Merge commit 'c311f6a175fd52da171795bc093762f4eba4c136' into macro11-v0.7.2
Update to latest released version of macro-11.

Command run: git subtree pull --prefix=crossassemblers/macro11 ../macro11 macro11-v0.7.2
(should be equivalent to git subtree pull --prefix=crossassemblers/macro11 git://gitlab.com/Rhialto/macro11.git macro11-v0.7.2)
2022-06-08 20:52:56 +02:00

54 lines
670 B
Plaintext

.mcall (at) always
.globl $write
.globl ndebug,sdebug, ..z,..zbuf
.globl savreg,dnc
.globl xx.flg
always
xitsec
sdebug:
call savreg
mov r0,-(sp)
mov #..s,r2
mov ..z,r3
mov #2,r0
1$: movb (r3)+,(r2)+
beq 2$
inc r0
br 1$
2$:
movb #12,(r2)
mov r0,..n
ddd:
tst xx.flg
beq 100$
mov ..n,-(sp) ;write(2, ..s, ..n)
mov #..s,-(sp)
mov #2,-(sp)
tst -(sp) ;simulate return address stack spacing
$write
add #8.,sp ;toss syscall cruft
100$:
mov (sp)+,r0
return
ndebug:
call savreg
mov r0,-(sp)
mov #..s,r2
mov ..z,r1
call dnc
movb #12,(r2)+
mov r2,..n
sub #..s,..n
br ddd
entsec mixed
..n: .blkw
..z: .word
..s: .blkw 100
..zbuf: .blkw 100
.end