1984-12-14 15:52:15 +00:00
|
|
|
.define _signal
|
1985-06-04 11:18:09 +00:00
|
|
|
.sect .text
|
|
|
|
.sect .rom
|
|
|
|
.sect .data
|
|
|
|
.sect .bss
|
1984-12-14 15:52:15 +00:00
|
|
|
.extern _signal
|
|
|
|
NSIG=32
|
1985-07-19 13:43:03 +00:00
|
|
|
.sect .text
|
1984-12-14 15:52:15 +00:00
|
|
|
_signal:
|
|
|
|
move.w 4(sp), d0
|
1985-06-04 11:18:09 +00:00
|
|
|
ext.l d0
|
1984-12-14 15:52:15 +00:00
|
|
|
cmp.l #NSIG,d0
|
|
|
|
bcc 1f
|
|
|
|
move.l 6(sp),d1
|
|
|
|
move.l d0,a0
|
|
|
|
add.l a0,a0
|
|
|
|
add.l a0,a0
|
|
|
|
add.l #dvect,a0
|
|
|
|
move.l (a0),a1
|
|
|
|
move.l d1,(a0)
|
|
|
|
beq 2f
|
|
|
|
btst #0,d1
|
|
|
|
bne 2f
|
1985-06-04 11:18:09 +00:00
|
|
|
move.l #enter,d1
|
1984-12-14 15:52:15 +00:00
|
|
|
2:
|
|
|
|
move.l d0,a0
|
|
|
|
move.w #0x30,d0
|
|
|
|
trap #0
|
|
|
|
bcs 3f
|
|
|
|
btst #0,d0
|
|
|
|
bne 4f
|
|
|
|
move.l a1,d0
|
|
|
|
4:
|
|
|
|
rts
|
|
|
|
1:
|
|
|
|
move.l #22,d0
|
|
|
|
3:
|
|
|
|
jmp cerror
|
|
|
|
|
|
|
|
enter:
|
|
|
|
movem.l d0/d1/a0/a1,-(sp)
|
1985-06-04 11:18:09 +00:00
|
|
|
move.l 16(sp),a0
|
|
|
|
move.l a0,-(sp)
|
1984-12-14 15:52:15 +00:00
|
|
|
add.l a0,a0
|
|
|
|
add.l a0,a0
|
|
|
|
add.l #dvect,a0
|
|
|
|
move.l (a0),a0
|
|
|
|
jsr (a0)
|
|
|
|
add.l #4,sp
|
|
|
|
movem.l (sp)+,d0/d1/a0/a1
|
|
|
|
add.l #4,sp
|
|
|
|
rtr
|
1985-06-04 11:18:09 +00:00
|
|
|
.sect .bss
|
1984-12-14 15:52:15 +00:00
|
|
|
dvect: .space 4*NSIG
|