Google
 

Trailing-Edge - PDP-10 Archives - BB-H348C-RM_1982 - swskit-v21/listings/rsx11s/drexp.list
There are no other files named drexp.list in the archive.
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3


      1						.TITLE	DREXP
      2						.IDENT	/01/
      3
      4					;
      5					; COPYRIGHT (C) 1976, 1978
      6					; DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.
      7					;
      8					; THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
      9					; OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
     10					;
     11					; VERSION 01
     12					;
     13					; T. J. MILLER 8-JUL-76
     14					;
     15					; MODIFIED BY:
     16					;
     17					;	T. J. MILLER 7-DEC-76
     18					;
     19					;		TM069 -- ADD CHECK FOR OUTSTANDING TERMINAL I/O.
     20					;
     21					;	T. J. MILLER 10-JAN-77
     22					;
     23					;		TM072 -- DISALLOW DECREASE IN SIZE FOR TASK'S WITH
     24					;			RESIDENT OVERLAYS.
     25					;
     26					;	T. J. MILLER 2-NOV-77
     27					;
     28					;		TM115 -- DISALLOW DECREASE IN SIZE BELOW OTHER
     29					;			WINDOWS MAPPED IN TASK PARTITION (REMOVING
     30					;			TM072 CHECK).
     31					;
     32					; MACRO LIBRARY CALLS
     33					;
     34
     35						.MCALL	HWDDF$,HDRDF$,PCBDF$,TCBDF$
     36	000000					HWDDF$			;DEFINE HARDWARE OFFSETS
     37	000000					HDRDF$			;DEFINE TASK HEADER OFFSETS
     38	000000					PCBDF$			;DEFINE PARTITION CONTROL BLOCK OFFSETS
     39	000000					TCBDF$			;DEFINE TASK CONTROL BLOCK OFFSETS
     40
     41					;+
     42					; **-$DREXP-EXTEND PARTITION
     43					;
     44					; THIS DIRECTIVE INSTRUCTS THE SYSTEM TO EXTEND THE PARTITION OF THE
     45					; ISSUING TASK BY A POSITIVE OR NEGATIVE INCREMENT.
     46					;
     47					; DPB FORMAT:
     48					;
     49					;	WD. 00 -- DIC(89.),DPB SIZE(3.).
     50					;	WD. 01 -- EXTEND INCREMENT.
     51					;	WD. 02 -- RESERVED.
     52					;
     53					; INPUTS:
     54					;
     55					;	R2=ADDRESS OF THE SECOND TASK STATUS WORD OF THE CURRENT TASK.
     56					;	R3=ADDRESS OF THE EXTEND INCREMENT IN THE DPB.
     57					;	R4=ADDRESS OF THE HEADER OF THE CURRENT TASK.
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3-1


     58					;	R5=ADDRESS OF THE TCB OF THE CURRENT TASK.
     59					;
     60					; OUTPUTS: (DIRECTIVE STATUS AND PS RETURNED TO TASK)
     61					;
     62					;	C=0 IF DIRECTIVE IS SUCCESSFULLY COMPLETED.
     63					;		DIRECTIVE STATUS OF '+1' IS RETURNED.
     64					;
     65					;	C=1 IF DIRECTIVE IS REJECTED.
     66					;		DIRECTIVE STATUS OF 'D.RS8' IF TASK NOT IN SYSTEM CON-
     67					;			TROLLED PARTITION, TASK IS NOT CHECKPOINTABLE
     68					;			AND SPECIFIED POSITIVE INCREMENT, OR TASK HAS
     69					;			PREALLOCATED CHECKPOINT SPACE AND IS EXTENDING
     70					;			GREATER THAN INSTALLED SIZE.
     71					;		DIRECTIVE STATUS OF 'D.RS88' IF SPECIFIED INCREMENT IS
     72					;			INVALID.
     73					;-
     74
     75
     76						.IF DF	D$$YNM&E$$XPR&M$$MGE
     77
     78					$DREXP::TSTB	T.IOC(R5)	;TASK HAVE OUTSTANDING I/O?
     79						BNE	15$		;IF NE YES
     80					 									; TM069
     81					 									; TM069
     82						.IF DF	A$$TRP&C$$CKP&T$$BUF					; TM069
     83					 									; TM069
     84						BIT	#T2.TIO,(R2)	;TASK HAVE OUTSTANDING TERMINAL I/O?	; TM069
     85						BNE	15$		;IF NE YES				; TM069
     86					 									; TM069
     87						.ENDC								; TM069
     88					 									; TM069
     89					 									; TM069
     90						MOV	T.PCB(R5),R0	;POINT TO TASK PCB
     91						BIT	#PS.SYS,P.STAT(R0) ;IS IT A SYSTEM CONTROLLED PARTITION?
     92						BEQ	67$		;IF EQ NO
     93						MOV	T.MXSZ(R5),R1	;ASSUME RETURNING TO INSTALLED SIZE
     94						MOV	(R3),R3		;PICK UP SPECIFIED INCREMENT
     95						BEQ	10$		;IF EQ DEFAULT TO INSTALLED SIZE
     96						ADD	P.SWSZ(R0),R3	;CALCULATE NEW SIZE
     97						MOV	R3,R1		;COPY NEW SIZE
     98					10$:	CMP	R1,P.SWSZ(R0)	;TASK INCREASING SIZE?
     99						BLOS	30$		;IF LOS NO
    100						CMP	R1,$MXEXT	;INCREASING PAST CURRENT MAXIMUM?
    101						BHI	45$		;IF HI YES				; TM072
    102						BIT	#T2.BFX!T2.CHK!T2.CKD!T2.FXD,(R2) ;TASK CHECKPOINTABLE?	;**-1
    103					15$:	BNE	67$		;IF NE NO
    104					20$:				;REF LABEL
    105
    106
    107						.IF DF	D$$YNC
    108
    109						BIT	#T3.CAL,2(R2)	;TASK HAVE CHECKPOINT SPACE ALLOCATED?
    110						BEQ	30$		;IF EQ NO
    111
    112						.ENDC
    113
    114
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3-2


    115						CMP	R1,T.MXSZ(R5)	;EXTENDING TO LARGER THAN INSTALLED SIZE?
    116						BHI	67$		;IF HI YES
    117					30$:	MOV	R1,-(SP)	;COPY NEW SIZE
    118						SWAB	(SP)		;CONVERT SIZE TO BYTES
    119						RORB	(SP)		;
    120						ROR	(SP)		;
    121						ROR	(SP)		;
    122
    123
    124						.IF DF	P$$LAS
    125
    126						CMP	R1,#200		;NEW SIZE GREATER THAN 4K?
    127						BHI	35$		;IF HI YES
    128
    129						.IFTF
    130
    131						CMP	(SP),H.HDLN(R4)	;NEW TASK SIZE SMALLER THAN HEADER?
    132						BLO	90$		;IF LO YES
    133
    134						.IFT
    135
    136					35$:	BIT	#T3.ROV,2(R2)	;TASK HAVE RESIDENT OVERLAYS?
    137						BNE	50$		;IF NE YES, IGNORE VIRTUAL ADDRESS CHKS
    138
    139						.ENDC
    140
    141
    142						MOV	H.WND(R4),R4	;POINT TO NUMBER OF WINDOW BLOCKS
    143						MOV	(R4)+,R2	;PICK UP NUMBER OF WINDOW BLOCKS
    144						TST	(R4)+		;POINT TO TASK LOW VIRTUAL ADDRESS
    145						MOV	(R4),R3		;PICK UP TASK LOW VIRTUAL ADDRESS
    146						ASL	R3		;CONVERT TO 32W BLOCKS
    147						ROL	R3		;
    148						ROLB	R3		;
    149						SWAB	R3		;
    150						ADD	R1,R3		;CALC HIGH VIRTUAL ADDRESS IN 32W BLOCKS
    151						CMP	R3,#2000	;LEGAL SIZE?
    152						BHIS	90$		;IF HIS NO
    153						ADD	(R4),(SP)	;CALCULATE NEW TOP VIRTUAL ADDRESS
    154					40$:	DEC	R2		;MORE WINDOW BLOCKS TO GO?
    155						BLE	50$		;IF LE NO
    156						ADD	#W.BLGH,R4	;POINT TO LOW VIRTUAL ADDRESS OF NEXT
    157						TST	W.BSIZ-W.BLVR(R4) ;ESTABLISHED WINDOW?
    158						BEQ	40$		;IF EQ NO
    159					 									; TM115
    160					 									; TM115
    161						.IF DF	P$$LAS							; TM115
    162					 									; TM115
    163						CMP	-2(R4),R0	;WINDOW MAPPED TO TASK REGION? (W.BPCB)	; TM115
    164						BNE	44$		;IF NE NO				; TM115
    165						MOV	2(R4),R3	;PICK UP HIGH VIRTUAL ADDRESS (W.BHVR)	; TM115
    166						SUB	(R4),R3		;CALCULATE LENGTH OF MAP - 1 (W.BLVR)	; TM115
    167						INC	R3		;CALCULATE LENGTH OF MAP		; TM115
    168						ASL	R3		;CONVERT TO 32W BLOCKS			; TM115
    169						ROL	R3		;					; TM115
    170						ROLB	R3		;					; TM115
    171						SWAB	R3		;					; TM115
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3-3


    172						ADD	W.BOFF-W.BLVR(R4),R3 ;CALCULATE LAST 32W BLOCK MAPPED	; TM115
    173						CMP	R1,R3		;REDUCING SIZE CONFLICT WITH WINDOW?	; TM115
    174						BLO	90$		;IF LO YES				; TM115
    175					 									; TM115
    176						.ENDC								; TM115
    177					 									; TM115
    178					 									; TM115
    179					44$:	CMP	(SP),(R4)	;VIRTUAL ADDRESS OVERLAP?		; TM115
    180						BLOS	40$		;IF LOS NO				;**-1
    181					45$:	BR	90$		;ILLEGAL SIZE				; TM072
    182					50$:	TST	(SP)+		;CLEAN STACK				;**-1
    183						MOV	P.MAIN(R0),R2	;POINT TO MAIN PARTITION PCB
    184						CMP	R1,P.SIZE(R2)	;MAIN PARTITION LARGE ENOUGH?
    185						BHI	90$		;IF HI NO
    186						MOV	R1,P.SWSZ(R0)	;SET SWAP SIZE FOR TASK PARTITION
    187						CLR	R4		;INITIALIZE END OF HOLE CALCULATION
    188						MOV	P.SUB(R0),R3	;POINT TO NEXT SUBPAR AFTER TASK PAR
    189						BNE	60$		;IF NE THERE IS ONE
    190						MOV	R2,R3		;ELSE POINT TO MAIN PARTITION
    191						ADD	P.SIZE(R3),R4	;CALCULATE END OF HOLE
    192					60$:	ADD	P.REL(R3),R4	;
    193						MOV	P.REL(R0),R3	;CALCULATE END OF DESIRED SPACE
    194						ADD	R1,R3		;
    195						CMP	R3,R4		;WILL EXTEND WORK IN PLACE?
    196						BLOS	70$		;IF LOS YES
    197						CALL	$SETRT		;FORCE RESCHEDULING
    198						MOV	R5,R1		;COPY TASK TCB ADDRESS
    199
    200
    201						.IF DF	D$$YNC
    202
    203						CALL	$CHKPT		;ATTEMPT TO CHECKPOINT TASK
    204						BIT	#TS.CKP,T.STAT(R5) ;WAS THE CHECKPOINT INITIATED?
    205						BEQ	65$		;IF EQ NO
    206						RETURN			;
    207					65$:	MOV	T.PCB(R5),R4	;PICK UP TASK PCB ADDRESS		; TM11X
    208						MOV	P.SIZE(R4),P.SWSZ(R4) ;RESET SWAP SIZE			; TM11X
    209						DRSTS	D.RS1		;POOL OR CHECKPOINT FILE ALLOC FAILURE	; TM11X
    210														;**-1
    211						.IFF
    212
    213						CALLR	$CHKPT		;INITIATE CHECKPOINT OF TASK
    214
    215						.ENDC
    216
    217
    218					67$:	DRSTS	D.RS8		;DIRECTIVE INCONSISTENT WITH TASK STATE
    219					70$:	CMP	R1,P.SIZE(R0)	;DECREASING TASK SIZE?
    220						BHIS	71$		;IF HIS NO
    221						MOV	#$NXTSK,-(SP)	;INSURE PARTITION WILL BE REALLOCATED
    222					71$:	MOV	R1,P.SIZE(R0)	;EXTEND TASK IN PLACE
    223
    224
    225						.IF DF	P$$LAS
    226
    227						BIT	#T3.ROV,T.ST3(R5) ;TASK HAVE RESIDENT OVERLAYS?
    228						BNE	80$		;IF NE YES, DO NOT CHANGE MAPPING
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3-4


    229
    230						.ENDC
    231
    232
    233						MOV	P.HDR(R0),R1	;POINT TO TASK'S HEADER
    234						MOV	H.WND(R1),R1	;POINT TO NUMBER OF WINDOW BLOCKS
    235						MOVB	W.BFPD+2(R1),R3	;PICK UP FIRST PDR ADDRESS
    236					74$:	CLR	(R3)+		;UNMAP NEXT PDR
    237						DECB	W.BNPD+2(R1)	;MORE TO GO?
    238						BNE	74$		;IF NE YES
    239						CALL	$MAPTK		;MAP TASK ADDRESS WINDOW
    240						MOV	P.REL(R0),R3	;CALCULATE FIRST APR OFFSET
    241
    242
    243						.IF DF	P$$LAS
    244
    245						ADD	W.BOFF-W.BLPD(R1),R3 ;
    246
    247						.ENDC
    248
    249
    250						MOV	(R1),R2		;PICK UP LAST PDR IMAGE
    251						MOVB	-(R1),R4	;PICK UP NUMBER OF PDR'S
    252						MOVB	-(R1),R1	;PICK UP FIRST PDR ADDRESS
    253					75$:	MOV	R3,UISAR0-UISDR0(R1) ;LOAD NEXT APR
    254						MOVB	R2,(R1)+	;SET ACCESS NEXT PDR
    255						MOVB	#177,(R1)+	;SET SIZE NEXT PDR
    256						ADD	#200,R3		;ADVANCE APR BASE
    257						DEC	R4		;MORE TO GO?
    258						BNE	75$		;IF NE YES
    259						MOV	R2,-(R1)	;SET LAST PDR
    260					80$:	RETURN			;
    261					90$:	DRSTS	D.RS84		;INVALID INCREMENT SPECIFIED
    262
    263						.ENDC
    264
    265
    266		000001 				.END
DREXP	MACRO M1110  22-AUG-79 06:59  PAGE 3-5
SYMBOL TABLE

AS.DEL= 000010   	H.HDLN  000002   	PR0   = 000000   	SR0   = 177572   	T2.FXD= 002000
AS.EXT= 000004   	H.IPC   000016   	PR1   = 000040   	SR3   = 172516   	T2.HLT= 000200
AS.RED= 000001   	H.IPS   000014   	PR4   = 000200   	SWR   = 177570   	T2.SPN= 000004
AS.WRT= 000002   	H.ISP   000020   	PR5   = 000240   	S$$YSZ= 001740   	T2.STP= 000020
A$$CHK= 000000   	H.LUN   000076   	PR6   = 000300   	TPS   = 177564   	T2.TIO= 001000
A$$CPS= 000000   	H.NLUN  000074   	PR7   = 000340   	TS.BLK= 170700   	T2.WFR= 000001
A$$TRP= 000000   	H.NML   000061   	PS    = 177776   	TS.CKP= 000200   	T3.ACP= 100000
A.IOC   000003   	H.ODVA  000022   	PS.APR= 000007   	TS.CKR= 000100   	T3.CAL= 000100
A.LGTH= 000014   	H.ODVL  000024   	PS.CHK= 010000   	TS.EXE= 100000   	T3.CLI= 001000
A.MPCT  000011   	H.OVLY  000054   	PS.CKP= 040000   	TS.MSG= 020000   	T3.MCR= 004000
A.PCB   000012   	H.PFVA  000032   	PS.CKR= 020000   	TS.NRP= 010000   	T3.NET= 000020
A.PCBL  000000   	H.RCVA  000036   	PS.COM= 000200   	TS.OUT= 000400   	T3.NSD= 000200
A.PRI   000002   	H.RRVA  000062   	PS.DEL= 000010   	TS.RDN= 040000   	T3.PMD= 040000
A.STAT  000010   	H.SPRI  000060   	PS.DRV= 000020   	TS.RUN= 004000   	T3.PRV= 010000
A.TCB   000004   	H.TKVA  000026   	PS.FXD= 004000   	T.ACTL  000052   	T3.REM= 020000
A.TCBL  000006   	H.TKVL  000030   	PS.LIO= 001000   	T.ASTL  000016   	T3.ROV= 000040
CMODE = 140000   	H.VEXT  000056   	PS.NSF= 000400   	T.ATT   000054   	T3.RST= 000400
C$$ORE= 002000   	H.WND   000044   	PS.OUT= 100000   	T.CPCB  000004   	T3.SLV= 002000
FE.CAL= 000040   	I$$RDN= 000000   	PS.PER= 002000   	T.DPRI  000040   	UBMPR = 170200
FE.CEX= 020000   	KDSAR0= 172360   	PS.PIC= 000100   	T.EFLG  000022   	UDSAR0= 177660
FE.DRV= 000010   	KDSDR0= 172320   	PS.SYS= 000040   	T.IOC   000003   	UDSDR0= 177620
FE.EXP= 000200   	KISAR0= 172340   	P$$RTY= 000000   	T.LBN   000041   	UISAR0= 177640
FE.EXT= 000001   	KISAR5= 172352   	P$$TPT= 000000   	T.LDV   000044   	UISAR4= 177650
FE.EXV= 000004   	KISAR6= 172354   	P.BLKS  000016   	T.LNK   000000   	UISAR5= 177652
FE.LSI= 000400   	KISAR7= 172356   	P.BUSY  000024   	T.MXSZ  000050   	UISAR6= 177654
FE.MUP= 000002   	KISDR0= 172300   	P.IOC   000003   	T.NAM   000006   	UISAR7= 177656
FE.MXT= 040000   	KISDR6= 172314   	P.LNK   000000   	T.OFF   000060   	UISDR0= 177600
FE.NLG= 100000   	KISDR7= 172316   	P.MAIN  000012   	T.PCB   000046   	UISDR4= 177610
FE.PKT= 000100   	K$$CNT= 177546   	P.NAM   000004   	T.PRI   000002   	UISDR5= 177612
FE.PLA= 000020   	K$$CSR= 177546   	P.OWN   000026   	T.RCVL  000012   	UISDR6= 177614
G$$TPP= 000000   	K$$IEN= 000115   	P.PRI   000002   	T.RRFL  000064   	UISDR7= 177616
G$$TTK= 000000   	K$$LDC= 000001   	P.REL   000014   	T.SRCT  000063   	V$$CTR= 001200
H$$RTZ= 000074   	K$$TPS= 000074   	P.SIZE  000016   	T.STAT  000032   	V$$RSN= 000031
H.CSP   000000   	L$$ASG= 000000   	P.STAT  000030   	T.ST2   000034   	W.BATT  000006
H.CUIC  000010   	L$$DRV= 000000   	P.SUB   000010   	T.ST3   000036   	W.BFPD  000014
H.DSW   000046   	MPAR  = 172100   	P.SWSZ  000022   	T.TCBL  000030   	W.BHVR  000004
H.DUIC  000012   	MPCSR = 177746   	P.TCB   000026   	T.UCB   000026   	W.BLGH  000020
H.EFLM  000004   	M$$CRB= 000124   	P.WAIT  000020   	T2.ABO= 000100   	W.BLPD  000016
H.EFSV  000040   	M$$MGE= 000000   	R$$DER= 000000   	T2.AST= 100000   	W.BLVR  000002
H.FCS   000050   	M$$NET= 000000   	R$$EXV= 000000   	T2.BFX= 004000   	W.BNPD  000015
H.FORT  000052   	M$$NT2= 000000   	R$$SND= 000000   	T2.CAF= 000400   	W.BOFF  000012
H.FPSA  000042   	N$$LDV= 000001   	R$$11M= 000000   	T2.CHK= 020000   	W.BPCB  000000
H.FPVA  000034   	PIRQ  = 177772   	R$$11S= 000000   	T2.CKD= 010000   	W.BSIZ  000010
H.GARD  000072   	PMODE = 030000   	SISDR0= 172200   	T2.DST= 040000   	X$$DBT= 000000

. ABS.	000102	   000
      	000000	   001
ERRORS DETECTED:  0

VIRTUAL MEMORY USED:  4121 WORDS  ( 17 PAGES)
DYNAMIC MEMORY:  5092 WORDS  ( 19 PAGES)
ELAPSED TIME:  00:00:17
[11,24]DREXP,SY0:[11,34]DREXP/-SP=[1,1]EXEMC/ML,[11,10]RSXMC/PA:1,DREXP