Google
 

Trailing-Edge - PDP-10 Archives - ap-c796e-sb - fc.mac
There are no other files named fc.mac in the archive.
;***COPYRIGHT(C) 1974 APPLIED DATA RESEARCH, INC., PRINCETON, N.J.***

;***THIS PROGRAM ASSEMBLED WITH FC.MAC***

	IFNDEF	FTLIST,<FTLIST==-1>	;ASSUME LISTING WANTED

	IFE	FTLIST,<XLIST>		;NO LISTING

	IFNDEF	FTARCH,<FTARCH==:0>	;ARCHIVE CODE
	IFNDEF	FTRECO,<FTRECO==:0>	;MTA ERROR RECOVERY CODE
	IFNDEF	FTDEBUG,<FTDEBUG==:0>	;PARANOIA CODE
	IFNDEF	FTIND,<FTIND==:-1>	;CODE TO DO ALL DSK IO INDEPENTENTLY

	IFNDEF	M,<M==:^D20>		;SIZE OF RECORD HEADER
	IFNDEF	N,<N==:5>		;NUMBER OF DISK BLOCKS PER RECORD

	IFNDEF	HMBNBR,<HMBNBR==:1>	;UNIT HOME BLOCK ADDRESS
	IFNDEF	FORMAT,<FORMAT==:1>	;FORMAT NUMBER
	IFNDEF	MAXSTR,<MAXSTR==:16>	;MAX NUMBER OF FS
	IFNDEF	NDSKOB,<NDSKOB==:8>	;OUTPUT BUFFERS
	IFNDEF	NDSKIB,<NDSKIB==:8>	;INPUT BUFFERS
	IFNDEF	NMTAOB,<NMTAOB==:4>	;NUMBER OF MTA OUTPUT BUFFERS
	IFNDEF	NMTAIB,<NMTAIB==:4>	;NUMBER OF MTA INPUT BUFFERS
	IFNDEF	NLSTOB,<NLSTOB==:2>	;NUMBER OF LST OUTPUT BUFFERS
	IFNDEF	PDLSIZ,<PDLSIZ==:70>	;SIZE OF PUSHDOWN LIST

	MAXLVL==:6			;MAX SFD LEVEL (CANNOT BE
					;ALTERED WITHOUT MESSING UP RECORDS)
	MAXCHR==:^D29			;MAX CH IN COMMENT (CANNOT BE
					;ALTERED WITHOUT MESSING UP RECORDS)

	MTBFSZ==:M+<200*N>		;SIZE OF RECORD ON TAPE

;DEVCHR BITS

	DV.MTA==:(1B13)			;DEVICE IS MTA
;REGISTER ASSIGNMENTS:

	S=:0		;STATUS FLAGS
	T1=:1		;TEMP
	T2=:T1+1	; ..
	T3=:T2+1	; ..
	T4=:T3+1	; ..
	P1=:T4+1	;PERMANENT
	P2=:P1+1	; ..
	P3=:P2+1	; ..
	P4=:P3+1	; ..
	LVL=:13		;SFD LEVEL COUNTER
	DBUF=:14	;DSK BUFFER ADDRESS
	MBUF=:15	;MTA BUFFER ADDRESS
	CH=:16		;ASCII CHARACTER
	P=:17		;PUSHDOWN POINTER

;MTA RECORD TYPES:

	TLBL==:1	;LABEL IDENTIFICATION RECORD
	TBEG==:2	;SAVE START
	TEND==:3	;SAVE END
	TFIL==:4	;DISK FILE DATA
	TUFD==:5	;UFD RIB

;LOCATIONS IN GENERAL RECORD:

	GEN0==:0	;LH = RECORD TYPE
			;RH = BITS
	NTAPE==:1	;RELATIVE TAPE WITHIN SAVE SET

;BITS IN GEN0 WORD:

	FRSEOF==:1B18	;LAST RECORD OF FILE
	RPTREC==:1B19	;REPEAT OF LAST RECORD (WRITE ERROR)
;LOCATIONS IN TLBL RECORD:

	LBLNAM==:2	;SIXBIT TAPE REEL NAME
	LBLTC==:3	;TIME OF LABELING
	LBLDC==:4	;DATE OF LABELING
	LBLDD==:5	;DATE OF DESTRUCTION
	LBLCOM==:6	;COMMENT

;LOCATIONS IN TBEG AND TEND RECORD:

	SVSNAM==:2	;SYSTEM NAME IN ASCII (WORDS 2 THRU 6)
	SVSVER==:7	;SYSTEM VERSION
	SVFMT==:10	;RETRIEVAL VERSION
	SVPRG==:11	;PROGRAM VERSION
	SVTIME==:12	;TIME OF START/END OF SAVE
	SVDATE==:13	;DATE OF START/END OF SAVE
	SVMODE==:14	;INIT MODE
	SVTRKS==:15	;NUMBER OF TRACKS
	SVNAME==:16	;SIXBIT SAVE NAME (OPTIONALLY SUPPLIED)
	SVPHYN==:17	;PHYSICAL NAME OF MTA USED FOR SAVE
	SVCOM==:20	;COMMENT

;LOCATIONS IN TFIL RECORD:

	FILSTR==:2	;STR OF FILE
	FILNAM==:3	;FILE NAME
	FILEXT==:4	;EXTENSION
	FILPPN==:5	;PROJ-PROG FOR FILE
	FILRDB==:6	;RELATIVE DATA BLOCK OF FILE
	FILCHK==:7	;CHECKSUM
	FILSDB==:10	;NUMBER OF SIGNIFICANT DATA BLOCKS IN RECORD
	FILSIZ==:11	;NUMBER OF WORDS WRITTEN IN LAST SIG BLOCK OF RECORD
	FILLVL==:12	;SFD LEVEL

;LOCATIONS IN TUFD RECORD:

	UFDSTR==:2	;STR OF UFD
	UFDLVL==:3	;UFD LEVEL (UFD=0, SFD1=1, ETC.)
;EXTENDED LOOKUP/ENTER/RENAME ARGUMENTS:
;* IMPLIES ACTUAL RIB INFO WILL BE USED IN ENTERING A FILE
;& IMPLIES ZERO WILL BE SUPPLIED INSTEAD OF ACTUAL RIB INFO
;% IMPLIES ZERO MUST BE SUPPLIED TO SUPPORT ALIAS CODE

	RIBCNT==:0	;COUNT OF ARGUMENTS FOLLOWING
	RIBPPN==:1	;* PROJ-PROG
	RIBNAM==:2	;* FILE NAME
	RIBEXT==:3	;* BITS 0-17 = EXTENSION
			;* BITS 18-23 = UNUSED
			;* BITS 24-35 = ACCESS DATE
	RIBPRV==:4	;* BITS 0-8 = PRIVILEGE BITS
			;* BITS 9-12 = MODE OF CREATION
			;* BITS 13-23 = TIME OF CREATION
			;* BITS 24-35 = DATE OF CREATION
	RIBSIZ==:5	;* WORD LENGTH OF FILE
	RIBVER==:6	;* OCTAL VERSION NUMBER
	RIBSPL==:7	;* FILENAME TO BE USED IN OUTPUT SPOOLING
	RIBEST==:10	;* ESTIMATED BLOCK LENGTH OF FILE
	RIBALC==:11	;* HIGHEST BLOCK ALLOCATED
	RIBPOS==:12	;% FIRST LOGICAL BLOCK WITHIN FS
	RIBFT1==:13	;* UNUSED
	RIBNCA==:14	;* NON-PRIVILEGED CUSTOMER ARGUMENT
	RIBMTA==:15	;* TAPE LABEL
	RIBDEV==:16	;% LOGICAL UNIT NAME ON WHICH THE FILE IS LOCATED
	RIBSTS==:17	;& LH = COMBINED STATUS OF ALL FILES IN UFD
			;& RH = STATUS OF THIS FILE
	  RP.DIR==:1B18	;* IF FILE IS A UFD
	  RP.NFS==:1B21	;* IF FILE IS NOT TO BE SAVED
	RIBELB==:20	;% BAD LOGICAL BLOCK WITHIN ERROR UNIT
	RIBEUN==:21	;% LH = LOGICAL UNIT NUMBER WITHIN FS OF BAD UNIT
			;% RH = NUMBER OF CONSECUTIVE BLOCKS IN BAD REGION
	RIBQTF==:22	;* (UFD-ONLY) FCFS LOGGED IN QUOTA IN BLOCKS
	RIBQTO==:23	;* (UFD-ONLY) LOGGED OUT QUOTA IN BLOCKS
	RIBQTR==:24	;* (UFD-ONLY) RESERVED LOGGED IN QUOTA
	RIBUSD==:25	;& (UFD-ONLY) NUMBER OF BLOCKS USED AT LAST LOGOUT
	RIBAUT==:26	;* AUTHOR PROJECT-PROGRAMMER NUMBER
	RIBNXT==:27	;& NEXT STR NAME IF FILE CONTINUED
	RIBPRD==:30	;& PREDECESSOR STR NAME IF FILE CONTINUED
	RIBPCA==:31	;* PRIVILEGED CUSTOMER ARGUMENT
	RIBUFD==:32	;% LOGICAL BLOCK NUMBER WITHIN FS OF THE RIB OF THE UFD
	RIBFLR==:33	;% RELATIVE BLOCK NUMBER IN FILE OF FIRST BLOCK IN RIB
	RIBXRA==:34	;% EXTENDED RIB ADDRESS
	RIBTIM==:35	;* CREATION DATE IN UNIVERSAL DATE-TIME STANDARD

	FRSLIM==:RIBTIM	;HIGHEST ARG TO BE USED
;HOME BLOCK WORDS

	HOMNAM==:0	;SIXBIT HOM
	HOMCNP==:16	;BP CLUSTER COUNT (E=7)
	HOMCKP==:17	;BP CHECKSUM (E=7)
	HOMCLP==:20	;BP CLUSTER ADDRESS (E=7)
	HOMMFD==:46	;LOGICAL BLOCK NUMBER WITHIN STR OF 1ST RIB FOR MFD

	MAXHOM==:HOMMFD	;HIGHEST ARG TO BE USED

;DSKCHR UUO WORDS:

	.DCSNM==:4	;FILE STRUCTURE NAME TO WHICH THIS UNIT BELONGS
	.DCUCH==:5	;BITS 0-8 = BLOCKS PER CLUSTER
			;BITS 9-17 = BLOCKS PER TRACK
			;BITS 18-35 = BLOCKS PER CYLINDER

	MAXDCH==:.DCUCH	;HIGHEST SIGNIFICANT DSKCHR WORD

;CLOSE UUO BITS:

	CLSOUT==:1B35	;INHIBIT OUTPUT CLOSE
	CLSIN==:1B34	;INHIBIT INPUT CLOSE
	CLSDLL==:1B33	;INHIBIT DEALLOCATION OF UNUSED BLOCKS
	CLSACS==:1B32	;INHIBIT UPDATING OF ACCESS DATE
	CLSNMB==:1B31	;INHIBIT DELETION OF NAME BLOCK
	CLSRST==:1B30	;RESET FILE
	CLSDAT==:1B29	;DELETE ACCESS TABLES

;MTA GETSTS BITS:

	IOIMPM==:1B18	;WRITE-LOCKED
	IODERR==:1B19	;DATA MISSED/TAPE BAD/TRANSPORT HUNG
	IODTER==:1B20	;PARITY ERROR
	IOBKTL==:1B21	;RECORD READ FROM TAPE EXCEEDS BUFFER SIZE
	IOEOF==:1B22	;EOF MARK ENCOUNTERED
	IOACT==:1B23	;DEVICE IS ACTIVE
	IOBOT==:1B24	;BEGINNING OF TAPE
	IOEOT==:1B25	;PHYSICAL END OF TAPE
	IOPAR==:1B26	;0 FOR ODD/1 FOR EVEN
	IOD200==:1B28	;200 BPI
	IOD556==:2B28	;556 BPI
	IOD800==:3B28	;800 BPI
	IODCLR==:3B28	;CLEAR BITS
	IONRC==:1B29	;SUPPRESS AUTOMATIC TAPE BEFUDDLING
;INPUT/OUTPUT CHANNELS:

	UFD==:0		;UFD
	ATDR1==:11	;ARCHIVE TAPE DIRECTORY
	ATDR2==:12	;ARCHIVE TAPE DIRECTORY
	MTA==:13	;MAG TAPE
	MFD==:14	;MASTER FILE DIRECTORY
	FILE==:15	;FILE
	STR==:16	;STR
	LST==:17	;LIST DEVICE

;ASCII CHARACTERS:

	CTRLC==:3	;CONTROL-C
	BELL==:7	;CONTROL-G
	HT==:11		;HORIZONTAL TAB
	LF==:12		;LINE FEED
	VT==:13		;VERTICAL TAB
	FF==:14		;FORM FEED
	CR==:15		;CARRIAGE RETURN
	CTRLZ==:32	;CONTROL-Z
	ALT33==:33	;ALTMODE
	SP==:40		;SPACE
	ALT175==:175	; ..
	ALT176==:176	; ..

;GETTAB TABLES:

	CNFTBL==:11	;CONFIGURATION DATA
	  SYSNAM==:0	;SYSTEM NAME
	  MONVER==:34	;MONITOR VERSION
	LVDTBL==:16	;LEVEL D DISK PARAMETERS
	  MFDPPN==:0	;PPN FOR MASTER FILE DIRECTORY
;BITS IN LH OF AC-S:

	ALIAS==:(1B0)		;ALIAS BEING DECODED
				;ASSUMED TO BE SIGN BIT
	UFDHAV==:(1B1)		;UFD BLOCK SEEN
	NUSETI==:(1B2)		;DO NOT USE SUPER USETI'S FOR FILE CHECKING
	FSTBLK==:(1B3)		;FILE BLOCK SEEN
	UFD1==:(1B4)		;FIRST FILE USED IN UFD
	FLOP==:(1B5)		;BUBBLE INVERSION
	STR1==:(1B6)		;FIRST TIME FS USED
	CCLST==:(1B7)		;CCL START
	SPECH==:(1B8)		;FILE SPEC ENCOUNTERED
	EQH==:(1B9)		;EQUALS SIGN SEEN
	RWD1==:(1B10)		;REWIND TAPE BEFORE USING
	EOT1==:(1B11)		;SKIP TO EOT BEFORE USING
	RWD2==:(1B12)		;REWIND TAPE AFTER USING
	UNL2==:(1B13)		;UNLOAD TAPE AFTER USING
	IND==:(1B14)		;INDEPENDENT DSK IO
	SHORT==:(1B15)		;LIST DEVICE IS TTY
	NSCATR==:(1B16)		;SCATTER FILES ON LOGICAL UNITS
	SKP1==:(1B17)		;SKIP BEFORE USING

;BITS IN RH OF AC-S:

	RDEOF1==:1B18		;FIRST EOF
	RDEOF2==:1B19		;SECOND EOF
	U1==:1B20		;ONE
	U2==:1B21		; ..
	ENCINI==:1B22		;ENCRIPTION CODE INITIALIZED
	PAOFLG==:1B23		;PARTIAL ALLOCATION ONLY
	FIPROG==:1B24		;FILE SAVE IN PROGRESS
	ARCMOD==:1B25		;ARCHIVE MODE
	SFLMAT==:1B26		;FILE SPECIFICATION MATCHED

;LOOKUP/ENTER/RENAME ERROR CODES:

	IPPERR==:1	;NON-EXISTANT UFD FOR GIVEN PPN
	PAOERR==:17	;PARTIAL ALLOCATION ONLY
	SNFERR==:23	;SFD NOT FOUND

	LIST
	IFE	FTLIST,<TAPE>
	IFN	FTLIST,<PAGE>