Trailing-Edge
-
PDP-10 Archives
-
tops10_703_distr_bb-x140b-sb
-
10,7/703anf/dntrce.p11
There are 3 other files named dntrce.p11 in the archive. Click here to see a list.
.SBTTL DNTRCE - TRACE 28 MAR 79
;THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
; OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
;
;COPYRIGHT (C) 1976,1977,1978,1979,1980,1981,1984 BY DIGITAL EQUIPMENT CORP., MAYNARD, MASS.
VRTRCE=007 ;FILE EDIT NUMBER
.IF NE FTRACE
Q=6 ;SAVE AT LEAST PART OF THE STACK
.MACRO X DATA
MOV DATA,(R0)+ ;PUT DATA INTO THE TRACE
Q=Q+2
.ENDM X
.MACRO XX DATA
MOV DATA,(R0)+ ;PUT DATA INTO THE TRACE
MOV @DATA,(R0)+
Q=Q+4
.ENDM XX
TRACE.: PIOFF
MOV NXMVEC,-(P) ;SAVE BUS TRAP VECTOR
MOV #80$,NXMVEC ;THEN SET NEW TRAP ADRESS
MOV R0,-(P) ;SAVE OLD R0
MOV R1,-(P) ;WE NEED A SCRATCH AC
MOV TR.PTR,R0 ;GET TRACE POINTER
X LOWUP ;PUT TIME INTO THE TRACE
X J ;SAVE DDB/LBLK POINTER
.IF NE FTDL10
TST J ;ARE WE LOOKING AT THE DL10?
BGE 10$ ;NO, PROBABLY CONTROL BLOCK
CLR (R0)+ ;STORE 0 INSTEAD OF ACCESSING WINDOW
BR 20$
.ENDC
10$: X @J ;STORE STATUS WORD
20$:
.IIF NE FT27.T, X DB.BCD(J) ;SAVE 2741 STATUS
.IIF NE FTNC.T, XX SB ;PUT STATION BLOCK POINTER INTO TRACE
.IF NE FTDQ.T
CMP J,#LBLK0 ;ONLY TRUST J IF IT LOOKS OKAY
BLO 30$ ;TOO LOW
CMP J,#LBLK0+<NTLINE*LB.SIZ>
BHIS 30$ ;TOO HIGH
MOV LB.SLA(J),R1
X @R1 ;PUT DQ11 RCV STATUS INTO TRACE
X 2(R1) ;PUT DQ11 XMT STATUS INTO TRACE
X 4(R1) ;PUT REG/ERR STATUS INTO TRACE
BR 40$ ;SKIP CLEAR CODE
30$: CLR (R0)+ ;J NOT SETUP, LEAVE CLEAR
CLR (R0)+
CLR (R0)+
40$:
.ENDC;.IF NE FTDQ.T
X 2(P) ;PUT R0 INTO TRACE
X @P ;PUT R1 INTO TRACE
X R2 ;PUT R2 INTO TRACE
X R3 ;PUT R3 INTO TRACE
.IF NE FTNC.T
X DNA ;PUT DESTINATION SCB ADR IN TRACE
X SNA ;PUT SOURCE SCB ADR IN TRACE
.ENDC;.IF NE FTNC.T
CMP 0,#ERRINT
BEQ 74$
73$: TRAP
74$:
;HERE TO BE SURE TRACE ENTRY'S LOOK NICE ON DUMP
QQ=100
.IIF EQ <<Q-1>&740>,QQ=40
.IIF EQ <<Q-1>&760>,QQ=20
MOV P,R1 ;FILL BLOCK WITH STACK
SUB #6,R1 ;COMPENSATE FOR WHAT WE PUT ON STACK
17$: BIT #QQ-1,R0 ;HAVE WE HIT END OF LINE FOR DUMP ?
BEQ 21$ ;IF SO DONE
CLR (R0)+ ;NOT YET SO CLEAR REST OF ENTRY
BR 17$
21$: CMP R0,#TR.QUE+TR.SIZ ;HIT END OF TRACE AREA ?
BNE 90$
MOV #TR.QUE,R0 ;YES SO POINT TO BEGINING AGAIN
90$: MOV R0,TR.PTR ;SAVE TRACE POINTER
MOV (P)+,R1 ;RESTORE R1
MOV (P)+,R0 ;RESTORE R0
MOV (P)+,NXMVEC ;RESTORE BUS TRAP VECTOR
PION ;RESTORE PROCESSOR STATUS
99$: RTS PC
;HERE ON BUS TIMEOUTS
80$: CLR (R0)+ ;STORE 0 FOR NXM
RTI
TR.PTR: TR.QUE
.=.+77
.=<.&177700>
TR.SIZ=10000
TR.QUE: .BLKB TR.SIZ
.ENDC;.IF NE FTRACE