Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-10 - 43,50517/xpnppl.mac
There are 7 other files named xpnppl.mac in the archive. Click here to see a list.
TITLE	XPNPPL FOR RPGII 1A(1)
		
SUBTTL	HANDLE APR TRAPS	AL BLACKINGTON/CAM/RBC

;COPYRIGHT 1974, DIGITAL EQUIPMENT CORP., MAYNARD, MA.
;MODIFIED TO RPGII VERSION JUNE 25,1975		BOB CURRIER

TWOSEG
RELOC	400000

ENTRY XPNPPL
EXTERNAL KILL

;THIS ROUTINE HANDLES APR TRAPS FOR:
;	1) ILLEGAL MEMORY REFERENCES (MEMORY PROTECTION FAILURE)
;	2) NON-EXISTENT MEMORY REFERENCES
;	3) PUSH-DOWN OVERFLOW (EXCEPT PHASE E -- SEE XPNPPE)


XPNPPL:	MOVEM	PP,KILLAC	;SAVE AC'S
	MOVE	PP,ACXWD
	BLT	PP,KILLAC+3

	MOVE	TA,.JBCNI##	;GET APR FLAGS

	TRNE	TA,1B19		;PUSH-DOWN OVERFLOW?
	JRST	XPNPL1		;YES

	TRNE	TA,1B22		;ILEGAL MEMORY REFERENCE?
	JRST	XPNPL2		;YES

	TRNE	TA,1B23		;NON-EXISTENT MEMORY?
	JRST	XPNPL3		;YES

	MOVEI	TA,[ASCIZ "Unknown APR trap"]
	JRST	XPNPL6

XPNPL1:	MOVEI	TA,[ASCIZ "Push-down overflow"]
	JRST	XPNPL6

XPNPL2:	SKIPA	TA,[EXP [ASCIZ "Illegal memory reference"]]

XPNPL3:	MOVEI	TA,[ASCIZ "Reference to non-existant memory"]
XPNPL6:	TTCALL	3,(TA)		;TYPE MESSAGE
	TTCALL	3,[ASCIZ " at location "]

	MOVE	TA,[POINT 3,.JBTPC##,17]	;TYPE OUT LOCATION

XPNPL7:	ILDB	TC,TA
	ADDI	TC,"0"
	TTCALL	1,TC
	TLNE	TA,770000
	JRST	XPNPL7

	TTCALL	3,[ASCIZ "
"]

	MOVS	PP,ACXWD	;RESTORE AC'S
	BLT	PP,TA
	MOVE	PP,KILLAC

	JRST	KILL


ACXWD:	XWD	TC,KILLAC+1

EXTERNAL KILLAC

	END