Trailing-Edge
-
PDP-10 Archives
-
BB-X116A-BB_1984
-
swihlp.mac
There are 4 other files named swihlp.mac in the archive. Click here to see a list.
TITLE .HELPR SWIL "HELP" processing module %5(41)
SUBTTL A.W.LYONS/AWL/PFC 17-OCT-73
SEARCH SWIDEF, SWIL ;SWIL PACKAGE DEFINTIONS
SEARCH JOBDAT, MACTEN, UUOSYM ;STANDARD DEFINITIONS
SALL ;PRETTY LISTINGS
.DIREC FLBLST ;PRETTIER LISTINGS
TWOSEG 400000 ;NICE PURE CODE
Copyright (C) Digital Equipment Corporation 1984.
COMMENT \
Copyright (C) 1984
Digital Equipment Corporation, Maynard, Massachusetts, U.S.A.
This software is furnished under a license and may be used and copied only
in accordance with the terms of such license and with the inclusion of the
above copyright notice. This software or any other copies thereof may not
be provided or otherwise made available to any other person. No title to
and ownership of the software is hereby transferred.
The information in this software is subject to change without notice and
should not be construed as a commitment by Digital Equipment Corporation.
Digital assumes no responsibility for the use or reliability of its
software on equipment which is not supplied by Digital.
\
CUSTVR==0 ;CUSTOMER VERSION
DECVER==5 ;DEC VERSION
DECMVR==0 ;DEC MINOR VERSION
DECEVR==41 ;DEC EDIT NUMBER
XP %HELPR,CUSTVR*1B2+DECVER*1B11+DECMVR*1B17+DECEVR
PURGE CUSTVR,DECVER,DECMVR,DECEVR
;REVISION HISTORY
;%4(35) JAN 1972
;36 (10-9713) HANDLE SEQUENCED FILES AND I/O ERRORS
;37 (10-11567) HANDLE HLP:
;40 ADD ALTERNATE ENTRY 'HELPER' FOR FORTRAN/COBOL
;41 EXPAND SORRY MESSAGE
;HELPER IS A SUBROUTINE USED TO OUTPUT HELP TEXTS(HLP:/SYS:??????.HLP)
; ONTO DEVICE TTY. IT WAS DESIGNED AS A TOOL FOR THE VARIOUS
; MODULES OF THE MULTI-PROGRAMMING-BATCH PROJECT.
;
;ENTERED WITH THE SIXBIT MODULE NAME IN AC1 VIA:
; PUSHJ P,.HELPR
; RETURN TO HERE AT END OF HELPER
;
;OR MOVEI 16,[,,['MODULE']]
; PUSHJ 17,HELPER
;
;HELPER REQUIRES EIGHT(8) LOCATIONS ON THE PUSH-DOWN LIST
; ON WHICH TO STORE AND FROM WHICH TO RESTORE USER AC'S.
;ACCUMULATORS
T1=1
T2=2
T3=3
T4=4
AP=16 ;ARG LIST POINTER
P=17
;DEVICE CHANNELS
DSK=0
ENTRY .HELPR,HELPER
HELPER: MOVE T1,@(AP) ;FETCH FIRST ARG
.HELPR: PUSH P,T2 ;SAVE ACS THAT ARE USED
PUSH P,T3
PUSH P,T4
PUSH P,.JBFF ;SAVE .JBFF
MOVE T2,.JBREL ;GET ACTUAL CORE SIZE
HRLM T2,(P) ;SAVE FOR RESTORATION
SETZ T2, ;TO LOAD BUFFER HEADER INTO PDL
PUSH P,T2 ; LOAD UP 4 ZEROED LOCATIONS
PUSH P,T2
PUSH P,T2
PUSH P,T2
GETHLP: SKIPA T3,['HLP '] ;GET HLP:
GETSYS: MOVSI T3,'SYS'
HRRZI T4,-2(P)
OPEN DSK,T2
JRST SORRY
MOVSI T2,'HLP'
SETZB T3,T4
LOOKUP DSK,T1
TLZA T2,-1 ;CLEAR JUNK
JRST MORE ;GOOD--GO READ FILE
CAIE T2,ERSNF%
CAIN T2,ERSLE%
JRST AGAIN
CAILE T2,ERIPP%
JRST SORRY ;HORRIBLE DISK ERROR
AGAIN: SETZM T2 ;CLEAR PHYSICAL BIT
AOS T3,-3(P) ;TRY NEXT CASE
TRNE T3,1 ;SEE IF ODD
TXO T2,UU.PHS ;YES--TRY PHYSICAL ONLY
JRST @[GETHLP ;TRY HLP: AGAIN
GETSYS ;THEN LOGICAL SYS:
GETSYS ;THEN PHYSICAL SYS:
SORRY]-1(T3) ;THEN GIVE UP
MORE: IN DSK,
JRST GETCHR
STATZ DSK,IO.ERR ;SEE IF ERRORS
JRST IOERR ;YES--ISSUE MESSAGE
STATZ DSK,IO.EOF ; YET?
JRST DONE ;YES, ALL DONE!
GETCHR: SOSGE T2,(P)
JRST MORE
IBP -1(P) ;INCR CHAR POINTER
MOVE T1,@-1(P) ;GET THIS WORD
TRNE T1,1 ;SEE IF SEQUENCE NUMBER
JRST [AOS -1(P) ;YES--SKIP 5 MORE CHARS
MOVNI T1,5 ; ..
ADDM T1,(P) ; ..
JRST GETCHR]
LDB T1,-1(P)
OUTCHR T1
JRST GETCHR
IOERR: OUTSTR [ASCIZ \%HLRIOE I/O error reading help file\]
JRST SORRYX ;FINISH WITH SORRY MESSAGE [41]
SORRY: OUTSTR [ASCIZ /%HLRNHF No .HLP file on SYS:/]
SORRYX: OUTSTR [ASCIZ/; I'm sorry, I can't help you/]
DONE: OUTSTR [ASCIZ/
/]
RELEAS DSK,
SUB P,[4,,4] ;RESTORE PDL
POP P,T1 ;RETRIEVE .JBFF IN "T1"
HRRZM T1,.JBFF ;RESTORE .JBFF
HLRZ T1,T1 ;RETRIEVE .JBCOR
CORE T1,
JFCL ;IGNORE ERROR
POP P,T4
POP P,T3
POP P,T2
POPJ P, ;RETURN TO CALLER
XLIST ;LITERALS
LIT
LIST
RELOC
END