Trailing-Edge
-
PDP-10 Archives
-
AP-D480B-SB_1978
-
forini.mac
There are 13 other files named forini.mac in the archive. Click here to see a list.
TITLE FORINI %5A(662) - ROUTINE TO SELECT THE CURRENT FOROTS
SUBTTL D. TODD/DRT/HPW/DMN/MD/JNG/SWG 11-JUL-77
;THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
; OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
;COPYRIGHT (C) 1972,1977 BY DIGITAL EQUIPMENT CORPORATION
SUBTTL REVISION HISTORY
;401 ----- SAVING REGISTERS MAY FAIL
;475 ----- IMPLEMENT DBMS% ENTRY POINT.
;662 ----- RESET .JBOPS AFTER GETSEG OF FOROTS
.JBOPS=135
SEARCH FORPRM ;LOAD GLOBAL SYMBOL FROM FORPRM SYMBOL TABLE
VERNO==3 ;MAJOR VERSION NUMBER
VEDIT==662 ;MAJOR EDIT NUMBER
VMINOR==0 ;MINOR VERSION NUMBER
VWHO==0 ;WHO EDITED LAST
VERINI==BYTE(3)VWHO(9)VERNO(6)VMINOR(18)VEDIT
AC17=17 ;TEMP STACK AC BEFOR FOROTS IS LOADED
EXTERNAL .JBFF,.JBREL
LOC .JBOPS
BYTE (6)1(12)VFOROT(18)0
; FORINI checks for a current FOROTS system in the high
; segment and jumps to the FOROTS initilization code if
; it is present. If the high segment is non-existant or
; other than FOROTS, FORINI sets the left half of
; (.JBOPS) to the FOROTS system code and calls SELOTS to
; load the correct verson of FOROTS.
; FORINI contains the (RESET.) entry point which is
; declared as an EXTERN by all FORTRAN main programs.
; The DECsystem-10 LOADER resolves the undefined external
; symbol (RESET.) by loading FORINI into the users low
; segment during the FORTRAN LIBRARY search. FORINI is
; called for every RUN, START, and EXECUTE command.
SUBTTL FORINI REDEFINE FOROTS ENTRIES FORM INTERNAL TO EXTERNAL
INTERNAL FORER.,OPEN.,CLOSE.,RELEA.,IN.,OUT.,RTB.,WTB.
INTERNAL ENC.,DEC.,NLI.,NLO.,IOLST.,MTOP.,FIN.
INTERNAL FIND.,EXIT.,ALCOR.,ALCHN.,DECOR.,DECHN.
INTERNAL TRACE.,FUNCT.,DBMS. ;[475]
OPEN.=OPEN%
CLOSE.=CLOSE%
RELEA.=RELEA%
IN.=IN%
OUT.=OUT%
RTB.=RTB%
WTB.=WTB%
ENC.=ENC%
DEC.=DEC%
NLI.=NLI%
NLO.=NLO%
IOLST.=IOLST%
FIN.=FIN%
MTOP.=MTOP%
FIND.=FIND%
EXIT.=EXIT%
ALCOR.=ALCOR%
DECOR.=DECOR%
ALCHN.=ALCHN%
DECHN.=DECHN%
TRACE.=TRACE%
FUNCT.=FUNCT%
DBMS.=DBMS% ;[475]
SALL
SUBTTL FORINI - ROUTINE TO GET SELOTS
RELOC 0
ENTRY RESET.
RESET.: ;MAIN ENTRY FROM FORTRAN TO INITILIZE FOROTS
RESET ;RESET ALL SOWTWARE CHANNELS
HRRZ AC17,.JBFF ;GET THE FIRST FREE LOC IN THE LOW SEG
HRRM AC17,.JBOPS ;SAVE AS A BASE REG FOR FOROTS
MOVEI AC17,LOW.SZ ;[311] MUST HAVE ROOM FOR LOW SEG DATA BASE
ADDB AC17,.JBFF ;UPDATE .JBFF FOR THE STATIC LOW SEG
CAMG AC17,.JBREL ;IS ADDITIONAL CORE REQUIRED
JRST .+3 ;NO,
CORE AC17, ;YES, GET CORE FOR THE STATIC AREA
JRST RESERR ;CORE NOT AVAILABLE
HRRZ AC17,.JBOPS ;RE-LOAD THE BASE ADDRESS
MOVEM L,L(AC17) ;[401] SAVE AC 16
MOVEI L,(AC17) ;[401] USE IT FOR BLT
BLT L,15(AC17) ;[401] SAVE THE AC'S 0 TO 15
MOVE P4,.JBOPS ;GET THE BASE REG AND LEFT FLAGS
TLZN P4,-1 ;IF NON-ZERO, MUST GET FOROTS
JRST RESET2 ;FOROTS IN CORE GO INITIALIZE
MOVSI T1,1 ;FOROTS NOT AROUND, SET FLAG TO CLEAR
CORE T1, ;A POSSIBLE HIGH SEGMENT
JFCL ;IGNORE ERROS
MOVEI T1,SELOTS ;SET A POINT TO THE SELOTS ARG BLOCK
GETSEG T1, ;GET SELOTS
HALT ;HELP, SELOTS NO AROUND
;**; [662] INSERT @ RESET2-1 SWG 11-JUL-77
HRRZS .JBOPS ;[662] RESET SO NEXT TIME WON'T GETSEG
RESET2: HRRZ P4,.JBOPS
MOVE L,ACC.SV+16(P4) ;RELOAD THE LINK REGISTER
JRST INIT% ;GO TO FOROTS INITIALIZE ROUTINE
SELOTS: EXP SYSDEV
SIXBIT /FOROTS/
EXP 0,0,0,0
RESERR: TTCALL 3,[ASCIZ/
?NO CORE AVAILABLE - CAN NOT PROCEED
/]
CALLI 1,12
JRST RESET. ;CONTINUE TO TRY AGAIN
FORER.: PUSHJ P,FORER% ;GO TO THE HIGH SEG
END