Google
 

Trailing-Edge - PDP-10 Archives - klad_sources - klad.sources/param.mac
There are no other files named param.mac in the archive.
SUBTTL	*PARAM*	PROGRAM/SUBROUTINE PARAMETERS, V73G, NOV 12, 1973

;OPERATOR DEFINITIONS, SUBROUTINE CALLS - SHORT COMMAND FORM

OPDEF	PGMINT	[JSP	0,$PGMIN]	;PROGRAM SUBROUTINE INITIALIZATION
OPDEF	FATAL	[JSR	$FATAL]		;FATAL PROGRAMMING HALT
OPDEF	ERRHLT	[JSR	$ERHLT]		;PROGRAM ERROR HALT

	IFDEF	PSHLST,<
OPDEF	GO	[PUSHJ	P,]		;SUBROUTINE CALL
OPDEF	RTN	[POPJ	P,]		;SUBROUTINE RETURN 
OPDEF	PUT	[PUSH	P,]		;PUT DATA ON PUSH LIST
OPDEF	GET	[POP	P,]		;GET DATA FROM PUSH LIST >

	IFDEF	TYPIN,<
OPDEF	TTICHR	[JSP	0,$OPTLK]	;TTY, INPUT ANY CHARACTER
OPDEF	TTIYES	[JSP	0,$YESNO]	;TTY, NORMAL RETURN Y
OPDEF	TTINO	[JSP	0,$NOYES]	;TTY, NORMAL RETURN N
OPDEF	TTIOCT	[JSP	0,$TPOCT]	;TTY, INPUT OCTAL WORD
OPDEF	TTIDEC	[JSP	0,$TPDEC]	;TTY, INPUT DECIMAL WORD
OPDEF	TTICNV	[JSP	0,$TPCNV]	;TTY, INPUT CONVERTABLE WORD
OPDEF	TTLOOK	[JSP	0,$TTLK]	;TTY, KEYBOARD CHECK
OPDEF	TTALTM	[JSP	0,$TALTM]	;TTY, ALT-MODE CHECK>

	IFDEF	PRINT,<
OPDEF	PNTA	[JSR	0,$PRINT]	;PRINT ASCII WORD
OPDEF	PNTAF	[JSR	0,$PRNTF]	;FORCED
OPDEF	PNTAL	[JSR	17,$PRINT]	;PRINT ASCIZ LINE
OPDEF	PNTALF	[JSR	17,$PRNTF]
OPDEF	PNTCHR	[JSR	12,$PRINT]	;PRINT CHARACTER
OPDEF	PNTCHF	[JSR	12,$PRNTF]
OPDEF	PNT1	[JSR	1,$PRINT]	;PRINT ONE OCTAL DIGIT
OPDEF	PNT1F	[JSR	1,$PRNTF]
OPDEF	PNT2	[JSR	2,$PRINT]	;PRINT TWO OCTAL DIGITS
OPDEF	PNT2F	[JSR	2,$PRNTF]
OPDEF	PNT3	[JSR	3,$PRINT]	;PRINT THREE OCTAL DIGITS
OPDEF	PNT3F	[JSR	3,$PRNTF]
OPDEF	PNT5	[JSR	5,$PRINT]	;PRINT FIVE OCTAL DIGITS
OPDEF	PNT5F	[JSR	5,$PRNTF]
OPDEF	PNT6	[JSR	6,$PRINT]	;PRINT SIX OCTAL DIGITS
OPDEF	PNT6F	[JSR	6,$PRNTF]
OPDEF	PNTADR	[JSR	10,$PRINT]	;PRINT PHYSICAL ADDRESS
OPDEF	PNTADF	[JSR	10,$PRNTF]
OPDEF	PNTOCT	[JSR	14,$PRINT]	;PRINT FULL WORD OCTAL
OPDEF	PNTOTF	[JSR	14,$PRNTF]
OPDEF	PNTHW	[JSR	13,$PRINT]	;PRINT OCTAL HALF WORDS, 6 SP 6
OPDEF	PNTHWF	[JSR	13,$PRNTF]
OPDEF	PNTDEC	[JSR	15,$PRINT]	;PRINT DECIMAL, SUPRESS LEADING 0'S
OPDEF	PNTDCF	[JSR	15,$PRNTF]
OPDEF	PNTDS	[JSR	16,$PRINT]	;PRINT DECIMAL, SPACES FOR LD 0'S
OPDEF	PNTDSF	[JSR	16,$PRNTF]
OPDEF	PNTNM	[JSP	0,$PNTNM]	;PRINT PROGRAM NAME
OPDEF	TTYOUT	[JSR	$TYOUT]		;TTY EXEC MODE OUTPUT >
	IFDEF	TOGGLE,<
OPDEF	SWITCH	[JSP	0,$SWTCH]	;INPUT CONSOLE SWITCHES>
	IFNDEF	TOGGLE,<
OPDEF	SWITCH	[JSP	0,$SWTCH]	;USE C(SWTEXR) AS SWITCHES>

	IFDEF	KIMRGN,<
OPDEF	PNTMGN	[JSP	0,$PNTMG]	;PRINT MARGIN VALUE >
	IFNDEF	KIMRGN,<
OPDEF	PNTMGN	[JFCL]			;NO-OP>

	IFDEF	MEMMAP,<
OPDEF	MEMZRO	[JSP	0,$MZRO]	;ZERO MEMORY
OPDEF	MEMSEG	[JSR	$MSEG]		;SETUP MEMORY SEGMENT
OPDEF	MAPADR	[JSR	$MPADR]		;VIRTUAL TO PHYSICAL ADR CONVERT >
	IFDEF	MEMMAP,<IFDEF	EXCASB,<
OPDEF	MAPCNK	[JSR	$MPCNK]		;MAP MEMORY CHUNK >>
	IFDEF	MEMMAP,<IFDEF EXCASB,<IFDEF KI10,<
OPDEF	MAPSET	[JSR	$MPSET]		;SET KI10 EXEC PAGE MAP >>> 

	IFDEF	USRASB,<IFDEF	PRINT,<
OPDEF	DROPDV	[JSP	0,$DRPDV]	;CLOSE LOGICAL FILE, USER MODE>>

	IFDEF	SIXIN,<
OPDEF	TTSIXB	[JSP	0,$TSIXB]	;TTY, INPUT SIXBIT WORD>

	IFDEF	SIXOUT,<
OPDEF	PNTSIX	[JSR	$PNTSX]		;PRINT SIXBIT WORD
OPDEF	PNTSXF	[JSR	$PTSXF]		;FORCED >

	IFDEF	DFASB,<
OPDEF	PNTCW	[JSR	$PNTCW]		;PRINT DF10 CONTROL WORD
OPDEF	PNTCWF	[JSR	$PNTCF]		;FORCED >

	IFDEF	MODDVC,<
OPDEF	MODPCU	[JSP	0,$MODDV]	;MODIFY PERHIPERAL DEVICE CODE
	DEFINE	$MDSXB	(A,B)<
	<SIXBIT/A/>!B		;A DEVICE CODE IS B>>
;STANDARD PROGRAM ASSIGNMENTS

;DATA SWITCHES

CYCL50==400000		;50 CYCLE POWER
RSTART==200000		;RESTART TEST, PRINT TOTALS
TOTALS==100000		;PRINT TOTALS, CONTINUE

NOPNT==	040000		;INHIBIT ALL PRINT/TYPE OUT (EXCEPT FORCED)
PNTLPT==020000		;PRINT ALL DATA ON LPT (LOGICAL DEVICE, USER MODE)
DING==	010000		;RING BELL ON ERROR

LOOPER==004000		;ENTER EXERCISE/CHECK LOOP ON ERROR
ERSTOP==002000		;HALT ON TEST ERROR
PALERS==001000		;PRINT ALL ERRORS

FSTCYL==000400		;FAST CYCLE
TXTINH==000200		;INHIBIT ERROR TEXT

;ACCUMULATORS

	IFDEF	PSHLST,<
P=	17		;PUSHDOWN POINTER AC (IF PUSH LIST USED)>

;PDP-10 STANDARD PC CONTROL FLAGS

AROV==	400000			;ARITHMETIC OVERFLOW
CRY0==	200000			;CARRY 0
CRY1==	100000			;CARRY 1
FOV==	40000			;FLOATING POINT OVERFLOW
BIS==	20000			;BYTE INTERRUPT
USERF==	10000			;USER MODE
EXIOT==	4000			;USER PRIV I/O
FXU==	100			;FLOATING POINT UNDERFLOW
DCK==	40			;DIVIDE CHECK

;PDP-10 STANDARD ADDRESS ASSIGNMENTS

LUUO==	40			;UUO STORAGE, UUO 1-37
LUUOI==	41			;UUO SERVICE INSTRUCTION
;JOB DATA AREA EXTERNALS

POWER==20		;POWER FAIL AC SAVE STORAGE
JOBUUO==40
JOB41==	41
JOBREL==44
JOBDDT==74
JOBSYM==116
JOBUSY==117
JOBSA==	120
JOBFF==	121
JOBREN==124
JOBAPR==125
JOBCNI==126
JOBTPC==127
JOBOPC==130
JOBVER==137

;USER APR ASSIGNMENTS

PDLOVU==200000		;PUSHDOWN LIST OVERFLOW
MPVU==	20000		;MEMORY PROTECTION VIOLATION
NXMU==	10000		;NON-X-MEMORY
PARU==	4000		;PARITY ERROR
CLKU==	1000		;CLOCK
FOVU==	100		;FLOATING OVERFLOW
AROVU==	10		;ARITHMETIC OVERFLOW

;USER MODE PRINT OUTPUT CHANNEL ASSIGNMENTS

$DEVCH==17		;LOGICAL DEVICE CHANNEL
$DVCH1==16		;LOGICAL DEV UPDATE INPUT CHANNEL

	XLIST
	IFDEF	EXCASB,<LIST
;PDP-10 STANDARD APR CONO ASSIGNMENTS

IOCLR==	200000			;CLEAR ALL I/O DEVICES
CLKDIS==4000			;DISABLE CLOCK INTERRUPTS
CLKENB==2000			;ENABLE CLOCK INTERRUPTS
CLKCLR==1000			;CLEAR CLOCK FLAG
ANXCLR==10000			;KA10, CLEAR NON-X-MEMORY
INXCLR==100			;KI10

;PDP-10 STANDARD APR CONI ASSIGNMENTS, RIGHT HALF

CLKENB==2000			;CLOCK INTERRUPT ENABLED
CLK==	1000			;CLOCK FLAG
ANXM==	10000			;KA10, NON-X-MEMORY
INXM==	100			;KI10

;PDP-10 STANDARD PI CONO ASSIGNMENTS

PWFCLR==400000			;CLEAR POWER FAIL FLAG
PARCLR==200000			;CLEAR PARITY ERROR FLAG
PARDIS==100000			;DISABLE PARITY INTERRUPTS
PARENB==40000			;ENABLE PARITY INTERRUPTS
PICLR==	10000			;CLEAR PI SYSTEM
REQSET==4000			;SET PROGRAM PI REQUEST
CHNON==	2000			;TURN ON CHANNEL
CHNOFF==1000			;TURN OFF CHANNEL
PIOFF=	400			;TURN OFF PI SYSTEM
PION==	200			;TURN ON PI SYSTEM

;PDP-10 STANDARD PI CONI ASSIGNMENTS

PION==	200			;PI SYSTEM ON

;PDP-10 STANDARD PI CHANNEL ASSIGNMENTS

PICHN1==100			;PI CHANNEL 1
PICHN2==40			;PI CHANNEL 2
PICHN3==20			;PI CHANNEL 3
PICHN4==10			;PI CHANNEL 4
PICHN5==4			;PI CHANNEL 5
PICHN6==2			;PI CHANNEL 6
PICHN7==1			;PI CHANNEL 7
PICHNA==177			;ALL PI CHANNELS, 1 THRU 7

;PDP-10 SPECIAL COMPATABILITY ASSIGNMENTS

PAG==	010			;PAGING I/O DEVICE CODE - KI10

	XLIST
	IFDEF	KA10,<LIST
;KA10 APR CHANNEL ASSIGNMENTS

AAPRC1==1			;APR INTERRUPT CHANNEL

;KA10 APR CONO ASSIGNMENTS

APDCLR==400000			;CLEAR PUSHDOWN OVERFLOW
AABCLR==40000			;CLEAR ADDRESS BREAK
AMPCLR==20000			;CLEAR MEMORY PROTECTION
ANXCLR==10000			;CLEAR NON-X-MEMORY
AFODIS==400			;DISABLE FLOATING POINT OVERFLOW
AFOENB==200			;ENABLE FLOATING POINT OVERFLOW
AFOCLR==100			;CLEAR FLOATING POINT OVERFLOW
AOVDIS==40			;DISABLE OVERFLOW
AOVENB==20			;ENABLE OVERFLOW
AOVCLR==10			;CLEAR OVERFLOW

;KA10 APR CONI ASSIGNMENTS

APDLOV==200000			;PUSHDOWN OVERFLOW
AUSRIO==100000			;USER I/O
AADRBK==40000			;ADDRESS BREAK
AMPV==	20000			;MEMORY PROTECTION VIOLATION
ANXM==	10000			;NON-EXISTENT MEMORY
AFOENB==200			;FLT PT INTERRUPT ENABLED
AFOV==	100			;FLOATING POINT OVERFLOW
ATRPOS==40			;TRAPS OFFSET
AOVENB==20			;OVERFLOW INTERRUPT ENABLED
AOVFLO==10			;ARITHMETIC OVERFLOW

;KA10 PI CONI ASSIGNMENTS

APWRFL==400000			;POWER FAILURE
APARER==200000			;PARITY ERROR
APAREN==100000			;PARITY INTERRUPT ENABLED
>

	XLIST
	IFDEF	KI10,<LIST
;KI10 PC CONTROL FLAGS

LIP==	2000			;LAST INSTRUCTION PUBLIC
TN0==	400			;TN=00, NO TRAP ;TN=01, ARITH TRAP
TN1==	200			;TN=10, PDL OV  ;TN=11, TRAP 3

;KI10 SPECIAL EXEC MODE FLAGS

UOLIP==	400000			;UUO OLD L.I.P.
UOUSR==	4000			;UUO OLD USER

;KI10 APR CHANNEL ASSIGNMENTS

IAPRC1==1			;APR CLOCK CHANNEL
IAPRE1==10			;APR ERROR CHANNEL

;KI10 APR CONO ASSIGNMENTS

ITMSET==400000			;SET TIME OUT TIMER
ITMDIS==100000			;DISABLE TIME OUT
ITMENB==40000			;ENABLE TIME OUT
IASRTC==20000			;CLEAR AUTO RESTART
IASRTS==10000			;SET AUTO RESTART
IIOPFC==200			;CLEAR I/O PAGE FAIL
INXCLR==100			;CLEAR NON-X-MEM

;KI10 APR CONI ASSIGNMENTS, RIGHT HALF

ITMOUT==400000			;TIMER TIMED OUT
IPARER==200000			;PARITY ERROR
IPAREN==100000			;PARITY ENABLED
ITMOEN==40000			;TIME OUT ENABLED
IPWRFL==20000			;POWER FAIL
IASRTE==10000			;AUTO RESTART ENABLED
IIOPFL==200			;I/O PAGE FAIL
INXM==	100			;NON-X-MEMORY
;KI10 APR CONI ASSIGMENTS, LEFT HALF

IMLAPD==200000			;MEMORY OVERLAP DISABLED
IFMMAN==100000			;FAST MEMORY MANUAL
IMIPGD==40000			;MI PROGRAM DISABLE
ICNSLR==20000			;CONSOLE READ ONLY
ICNSLL==10000			;CONSOLE LOCKED
IP50HZ==4000			;50 HZ POWER
IMGINM==2000			;MANUAL MARGINS
IMAINT==1000			;MAINTENANCE MODE
IPWRLO==400			;POWER LOW
IMGNLO==200			;MARGIN COMPARATOR LOW
SENSE1==40			;SENSE SWITCHES		1
SENSE2==20			;			2
SENSE3==10			;			3
SENSE4==4			;			4
SENSE5==2			;			5
SENSE6==1			;			6

;KI10 APR DATAO ASSIGNMENTS

IEVNPR==20000			;WRITE EVEN PARITY
ISPDOF==10000			;SPEED MARGINS OFF
ISPDON==4000			;SPEED MARGINS ON
IMGNOF==2000			;MARGINS OFF - LH
IMGNON==1000			;MARGINS ON - LH

;KI10 PI CONO ASSIGNMENTS

IRQCLR==20000			;CLEAR PROGRAM PI REQUEST
;KI10 PI CONI ASSIGNMENTS

IINSTF==400000			;ADDRESS CONDITIONS, INST FETCH
IDATAF==200000			;	    	     DATA FETCH
IWRITE==100000			;		     WRITE
IADSTP==40000			;ADDRESS STOP
IADBRK==20000			;ADDRESS BREAK
IADEXC==10000			;ADDRESS SWITCHES EXEC
IADUSR==4000			;  "	  "       USER
IPRSTP==2000			;PARITY STOP
INXSTP==1000			;NON-X-MEM STOP

;KI10 PAG CONI ASSIGNMENTS

EXCMEM==400			;EXEC MEMORY SPACE
AMCLRB==40			;ASSOCIATIVE MEMORY CLEAR BIT

;KI10 PAG DATAO ASSIGNMENTS, LEFT HALF

LDUSRB==400000			;LOAD USER BASE REGISTER
SMLUSR==40000			;SMALL USER, 32K OR UNDER
USRCMP==20000			;USER ADR COMPARE ENABLE

;KI10 PAG DATAO ASSIGNMENTS, RIGHT HALF

LDEXCB==400000			;LOAD EXEC BASE REGISTER
TRPENB==20000			;ENABLE TRAPS

;KI10 PAG DATAI ASSIGNMENTS

SMLUSR==40000			;SMALL USER
USRCMP==20000			;USER ADR COMPARE ENABLED
TRPENB==20000			;RH, TRAPS ENABLED

;KI10 PTR DATAO ASSIGNMENTS

	;ADDRESS CONDITIONS, ADDRESS BREAK ;AS ABOVE, PI CONI
	;ADDRESS SWITCHES, 14-35
;KI10 EXEC PAGE MAP PAGE ASSIGNMENTS

PGFTRP==420			;PAGE FAULT TRAP
AROVTP==421			;ARITHMETIC TRAP
PDOVTP==422			;PUSHDOWN OVERFLOW TRAP
TRP3TP==423			;TRAP 3 TRAP

;KI10 USER PAGE MAP PAGE ASSIGNMENTS

PGFTRP==420			;PAGE FAULT TRAP
AROVTP==421			;ARITHMETIC TRAP
PDOVTP==422			;PUSHDOWN OVERFLOW TRAP
TRP3TP==423			;TRAP 3 TRAP

MUUO==	424			;MUUO STORAGE
MUUOPC==425			;C(PC) OF MUUO STORAGE

EXCPFW==426			;EXEC PAGE FAIL WORD
USRPFW==427			;USER PAGE FAIL WORD

KNTRP==	430			;KERNAL	 	NO TRAP - NEW PC'S-
KTRP==	431			;"	 	TRAP
SNTRP==	432			;SUPERVISOR	NO TRAP
STRP==	433			;"		TRAP
CNTRP==	434			;CONCEAL 	NO TRAP
CTRP==	435			;"		TRAP
PNTRP==	436			;PUBLIC		NO TRAP
PTRP==	437			;"		TRAP

>>
	LIST
	IFNDEF	PRGINH,<
	ASUPPRESS	>