Table of Contents

MFILES

Table Of Contents

  • [00015] MFILES - MULTIPLE FILE PROCESSOR.
  • [00228] ACON - SET ARGUMENT CONTROL.
  • [00243] SCON - SET COMMAND CONTROL.
  • [00333] TACW - TABLE OF ARGUMENT CONTROL WORDS.
  • [00350] TDSP - *DSP* PARAMETER BLOCK.
  • [00357] TSFN - TABLE OF SPECIAL FILE NAMES.
  • [00442] MFP - MULTIPLE FILE PROCESSOR.
  • [00474] SUBROUTINES.
  • [00476] ABT - ISSUE MESSAGE AND ABORT.
  • [00487] CFN - CHECK FILE NAME FOR EXCLUSION.
  • [00549] CIF - CHECK FOR INPUT* FILE.
  • [00566] CMS - CHECK FOR MASS STORAGE AND READ ONLY FILE.
  • [00630] COC - CHECK FOR OPTICAL CONTROL FILE *ZZZZZOD*.
  • [00651] COF - CHECK IF OUTPUT FILE.
  • [00727] CPF - CHECK FOR PROTECTED FILE.
  • [00799] GNF - GET NONBUSY FET.
  • [00841] IFC - ISSUE FILE COUNT MESSAGE.
  • [00878] IRJ - INDEX RETURN JUMP.
  • [00897] PAF - PROCESS ALL FILES.
  • [00935] POF - PROCESS ONE FILE.
  • [01012] RSR - RESTORE RESERVED REGISTERS.
  • [01038] SVR - SAVE RESERVED REGISTERS.
  • [01090] PRS - PRESET.
  • [01171] MOL - MOVE ** OPTIONS.

Source Code

MFILES.txt
  1. IDENT MFILES,FETS
  2. ABS
  3. SST
  4. ENTRY CLEAR
  5. ENTRY OUT
  6. ENTRY OVWRITE
  7. ENTRY RETURN
  8. ENTRY REWIND
  9. ENTRY SETFS
  10. ENTRY UNLOAD
  11. ENTRY NPC=
  12. ENTRY RFL=
  13. ENTRY SSM=
  14. SYSCOM B1
  15. TITLE MFILES - MULTIPLE FILE PROCESSOR.
  16. *COMMENT MFILES - MULTIPLE FILE PROCESSOR.
  17. COMMENT COPYRIGHT CONTROL DATA SYSTEMS INC. 1992.
  18. SPACE 4,10
  19. ***** MFILES - MULTIPLE FILE PROCESSOR.
  20. *
  21. * A. SKJOLDEBRAND. 75/09/07.
  22. * H. G. VARNIS. 79/01/02.
  23. *
  24. * *MFILES* REQUESTS THAT CERTAIN OPERATIONS BE PERFORMED ON A
  25. * SUBSET OF FILES ASSIGNED TO A JOB.
  26. MFILES SPACE 4,30
  27. *** *MFILES* REQUESTS THAT CERTAIN OPERATIONS BE PERFORMED ON A
  28. * SUBSET OF FILES ASSIGNED TO A JOB. THE SUBSET IS DEFINED BY
  29. * THE COMMAND AS FOLLOWS:
  30. *
  31. * FORMAT FORMAT SUBSET
  32. * CODE
  33. *
  34. * 0 NAME. ALL FILES
  35. * 1 NAME(*) ALL FILES
  36. * 2 NAME(*,LFN1,...,LFNN) ALL FILES EXCEPT LFN1,...,LFNN
  37. * 3 NAME(LFN1,...,LFNN) FILES LFN1,...,LFNN
  38. *
  39. * LEGAL COMMAND NAMES ARE *CLEAR*, *OUT*, *OVWRITE*,
  40. * *RETURN*, *REWIND*, *SETFS*, AND *UNLOAD*. OPERATIONS AND
  41. * ALLOWED FORMATS ARE GIVEN BY THE FOLLOWING TABLE.
  42. *
  43. * 0 1 2 3
  44. * --- --- --- ---
  45. * CLEAR RELEASE FILE FROM JOB X X X -
  46. * OUT RELEASE FILE TO OUTPUT QUEUE X X X -
  47. * OVWRITE OVERWRITE FILES - X X X
  48. * RETURN RELEASE FILE FROM JOB - X X X
  49. * REWIND POSITION FILE AT BOI - X X X
  50. * SETFS SET FILE STATUS - X X X
  51. * UNLOAD RELEASE FILE FROM JOB - X X X
  52. *
  53. * WHERE: X = FORMAT ALLOWED FOR THIS COMMAND.
  54. * - = FORMAT NOT ALLOWED FOR THIS COMMAND.
  55. *
  56. *
  57. * NOTES:
  58. *
  59. * 1. THE *CLEAR* AND *RETURN* COMMANDS PRODUCE
  60. * IDENTICAL OPERATIONS ON THE FILES TO WHICH THEY REFER.
  61. * THEY DIFFER ONLY IN ALLOWED COMMAND FORMATS.
  62. MFILES SPACE 4,20
  63. *** THE COMMAND.
  64. *
  65. *
  66. * CLEAR. RETURNS ALL FILES EXCEPT FOR FILES WITH
  67. * *CBST*, *CKST* OR *NDST* STATUS, AND
  68. * THE OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  69. *
  70. * CLEAR/OP=O. RETURNS ALL OPTICAL DISK FILES AND THE
  71. * OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  72. *
  73. * CLEAR(*) RETURNS ALL FILES EXCEPT FOR FILES WITH
  74. * *CBST*, *CKST* OR *NDST* STATUS, AND
  75. * THE OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  76. *
  77. * CLEAR(*/OP=O) RETURNS ALL OPTICAL DISK FILES AND THE
  78. * OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  79. *
  80. * CLEAR(*,LFN1,...,LFNN) RETURNS ALL FILES EXCEPT FOR
  81. * FILES LFN1,...,LFNN, FILES WITH *CBST*,
  82. * *CKST* OR *NDST* STATUS, AND THE OPTICAL
  83. * DISK CONTROL FILE *ZZZZZOD*.
  84. *
  85. *
  86. * OUT. RELEASES TO THE OUTPUT QUEUE ALL
  87. * FILES OF TYPE *QFFT* AND ALL FILES
  88. * WITH THE SPECIAL NAMES *OUTPUT*,
  89. * *PUNCH*, *PUNCHB*, AND *P8*.
  90. *
  91. * OUT(*) SAME AS *OUT.*
  92. *
  93. * OUT(*/OP=X) SAME AS *OUT.* USING THE OPTION *X*.
  94. * THIS FORM IS USED ONLY BY THE SYSTEM
  95. * DURING JOB TERMINATION PROCESSING.
  96. * THE POSSIBLE VALUES OF THE OPTION
  97. * *X* AND THEIR MEANINGS ARE SHOWN
  98. * BELOW.
  99. *
  100. * E PERFORM END-OF-JOB ROUTING.
  101. *
  102. * OUT(*,LFN1,...,LFNN) SAME AS *OUT* WITH THE
  103. * EXCEPTION OF FILES LFN1,...,LFNN.
  104. *
  105. *
  106. * OVWRITE,*. OVERWRITE ALL MASS STORAGE FILES EXCEPT
  107. * FOR FILES NOT IN WRITE MODE.
  108. *
  109. * OVWRITE,*/OP=OPTIONS. OVERWRITE ALL MASS STORAGE FILES
  110. * EXCEPT FOR FILES NOT IN WRITE MODE WITH
  111. * THE FOLLOWING OPTIONS.
  112. * Z - OVERWRITE THE FILE WITH BINARY ZEROES.
  113. * BOTH THE Z AND THE X OPTIONS CANNOT
  114. * BE SIMULTANEOUSLY SELECTED. THIS IS
  115. * THE DEFAULT VALUE.
  116. *
  117. * X - OVERWRITE THE FILE FIRST WITH BINARY
  118. * ZEROS, THEN WITH BINARY ONES, THEN
  119. * WITH A PATTERN OF ALTERNATING BINARY
  120. * ONES AND ZEROS.
  121. *
  122. * R - RETURN ALL FILES PROCESSED AFTER
  123. * COMPLETION.
  124. *
  125. * OVWRITE,*,LFN1,...,LFNN/OP=OPTIONS.
  126. * OVERWRITE ALL MASS STORAGE FILES EXCEPT
  127. * FOR FILES NOT IN WRITE MODE AND FILES
  128. * LFN1,...LFNN USING SELECTED OPTIONS.
  129. *
  130. * OVWRITE,LFN1,...,LFNN/OP=OPTIONS.
  131. * OVERWRITE FILES LFN1,...,LFNN USING
  132. * SELECTED OPTIONS. NON-MASS STORAGE FILES
  133. * AND FILES NOT IN WRITE MODE WILL BE
  134. * IGNORED.
  135. *
  136. *
  137. * RETURN(*) RETURNS ALL FILES EXCEPT FOR FILES WITH
  138. * *CBST*, *CKST* OR *NDST* STATUS, AND
  139. * THE OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  140. *
  141. * RETURN(*/OP=O) RETURNS ALL OPTICAL DISK FILES AND THE
  142. * OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  143. *
  144. * RETURN(*,LFN1,...,LFNN) RETURNS ALL FILES EXCEPT FOR
  145. * FILES LFN1,...,LFNN, FILES WITH *CBST*,
  146. * *CKST* OR *NDST* STATUS, AND THE OPTICAL
  147. * DISK CONTROL FILE *ZZZZZOD*.
  148. *
  149. * RETURN(LFN1,...LFNN) RETURNS FILES LFN1,...,LFNN.
  150. * WILL *NOT* RETURN THE OPTICAL DISK
  151. * CONTROL FILE *ZZZZZOD*.
  152. *
  153. *
  154. * REWIND(*) REWINDS ALL FILES.
  155. *
  156. * REWIND(*,LFN1,...,LFNN) REWINDS ALL FILES EXCEPT
  157. * FOR FILES LFN1,...,LFNN.
  158. *
  159. * REWIND(LFN1,...,LFNN) REWINDS FILES LFN1,...LFNN.
  160. *
  161. *
  162. * SETFS(*/FS=S) SET FILE STATUS *S* ON ALL FILES.
  163. *
  164. * SETFS(*,LFN1,...,LFNN/FS=S) SET FILE STATUS *S* ON ALL FILES
  165. * EXCEPT FILES LFN1,...,LFNN.
  166. *
  167. * SETFS(LFN1,...,LFNN/FS=S) SET FILE STATUS *S* ON FILES
  168. * LFN1,....,LFNN.
  169. *
  170. *
  171. * UNLOAD(*) UNLOADS ALL FILES EXCEPT FOR FILES WITH
  172. * *CBST*, *CKST* OR *NDST* STATUS, AND
  173. * THE OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  174. *
  175. * UNLOAD(*/OP=O) UNLOADS ALL OPTICAL DISK FILES AND THE
  176. * OPTICAL DISK CONTROL FILE *ZZZZZOD*.
  177. *
  178. * UNLOAD(*,LFN1,...,LFNN) UNLOADS ALL FILES EXCEPT FOR
  179. * FILES LFN1,...,LFNN, FILES WITH *CBST*,
  180. * *CKST* OR *NDST* STATUS, AND THE OPTICAL
  181. * DISK CONTROL FILE *ZZZZZOD*.
  182. *
  183. * UNLOAD(LFN1,...,LFNN) UNLOADS FILES LFN1,...LFNN.
  184. * WILL *NOT* UNLOAD THE OPTICAL DISK
  185. * CONTROL FILE *ZZZZZOD*.
  186. SPACE 4,10
  187. *** DAYFILE MESSAGES.
  188. *
  189. *
  190. * * ERROR IN ARGUMENTS.* = AN INCORRECT ARGUMENT OR FORMAT
  191. * WAS USED ON THE COMMAND. COMPARE THE
  192. * COMMAND USED WITH THE DOCUMENTED FORMATS.
  193. *
  194. * * FILE STATUS NOT SPECIFIED.* = A *SETFS* COMMAND WAS
  195. * ISSUED WITH NO FILE STATUS SPECIFIED.
  196. *
  197. * * INCORRECT FILE STATUS.* = THE FILE STATUS SPECIFIED
  198. * ON A *SETFS* COMMAND WAS NOT VALID.
  199. *
  200. * * INCORRECT */* OPTION.* = AN INCORRECT COMMAND
  201. * OPTION WAS ENTERED FOLLOWING A */* SEPARATOR.
  202. *
  203. * * NNN FILE(S) PROCESSED.* = NNN IS THE NUMBER OF FILES FOR
  204. * WHICH THE FUNCTION WAS REQUESTED.
  205. *
  206. * * XXXXXXX ROUTED. JSN IS YYYY.* = XXXXXXX IS THE NAME
  207. * OF THE FILE BEING ROUTED AND YYYY IS THE JSN WHICH
  208. * WAS ASSIGNED TO THAT FILES QFT ENTRY.
  209. *
  210. * * (FILENAME) NOT ON MASS STORAGE.* = THE NAMED FILE WAS NOT
  211. * PROCESSED BECAUSE IT DOES NOT RESIDE ON MASS STORAGE.
  212. *
  213. * * (FILENAME) NOT IN WRITE MODE.* = THE NAMED FILE WAS NOT
  214. * PROCESSED BECAUSE IT IS NOT IN WRITE MODE.
  215. MFILES TITLE CONSTANTS AND MACRO DEFINITIONS.
  216. MFILES SPACE 4,10
  217. ** DEFINITION COMMON DECKS.
  218.  
  219.  
  220. *CALL COMCMAC
  221. *CALL COMCCMD
  222. *CALL COMSDSP
  223. *CALL COMSJCE
  224. *CALL COMSLFD
  225. SPACE 4,15
  226. ** MACRO DEFINITIONS.
  227. ACON SPACE 4,10
  228. ** ACON - SET ARGUMENT CONTROL.
  229. *
  230. * ACON P,T
  231. *
  232. * ENTRY *P* = ARGUMENT PROCESSOR ADDRESS.
  233. * *T* = ARGUMENT TABLE (*COMCARG* FORMAT) ADDRESS.
  234. *
  235. * EXIT 24/0, 18/P, 18/T
  236.  
  237.  
  238. PURGMAC ACON
  239. ACON MACRO P,T
  240. + VFD 24/0,18/P,18/T
  241. ENDM
  242. SCON SPACE 4,10
  243. ** SCON - SET COMMAND CONTROL.
  244. *
  245. * SCON A,B,C,D,EXP,CF
  246. *
  247. * ENTRY *A* = 1 IF FORMAT 0 ALLOWED.
  248. * *B* = 1 IF FORMAT 1 ALLOWED.
  249. * *C* = 1 IF FORMAT 2 ALLOWED.
  250. * *D* = 1 IF FORMAT 3 ALLOWED.
  251. * *EXP* = ADDRESS OF FILE EXCLUSION PROCESSOR.
  252. * *CF* = *CIO* FUNCTION CODE.
  253.  
  254.  
  255. PURGMAC SCON
  256.  
  257. SCON MACRO A,B,C,D,EXP,CF
  258. VFD 1/A,1/B,1/C,1/D,20/0,18/EXP,18/CF
  259. ENDM
  260. MFILES SPACE 4,10
  261. **** INSTALLATION PARAMETERS.
  262.  
  263.  
  264. MNF EQU 200B FILES PROCESSED PER *GETFNT* CALL
  265. ****
  266. SPACE 4,10
  267. ** ASSEMBLY CONSTANTS.
  268.  
  269.  
  270. FMT0 EQU 0 FORMAT 0
  271. FMT1 EQU 1 FORMAT 1
  272. FMT2 EQU 2 FORMAT 2 (EXCLUSION FORMAT)
  273. FMT3 EQU 3 FORMAT 3 (INCLUSION FORMAT)
  274. FNTBL EQU 2*MNF+2 *GETFNT* BUFFER SIZE
  275. PSBFL EQU 1 LENGTH OF PSEUDO BUFFER FOR FETS
  276. FRDC EQU 20B *DSP* FLAG FOR DISPOSITION CODE
  277. MFILES TITLE TABLES AND DATA STORAGE.
  278. ** FETS.
  279.  
  280.  
  281. ORG 110B
  282. FETS BSS 0
  283. FET1 FILEB PSBF,PSBFL,(FET=8)
  284. FET2 FILEB PSBF,PSBFL,(FET=8)
  285. FET3 FILEB PSBF,PSBFL,(FET=8)
  286. FETX FILEB PSBF,PSBFL,(FET=13) *GETFNT* FET (MUST BE LAST FET)
  287.  
  288. FETC EQU FETX+8 *GETFNT* CONTROL WORD ADDRESS
  289. FETL EQU FET2-FET1 FET LENGTH
  290. FETW EQU FETX-FETS LENGTH OF FET BLOCK
  291. FETN EQU FETW/FETL+1 NUMBER OF FETS
  292. SPACE 4,10
  293. ** RESERVED LOCATIONS.
  294.  
  295.  
  296. CSOC CON 0 COMMAND OPTION COUNT
  297. EOJS CON 0 END-OF-JOB PROCESSING STATUS
  298. FICT CON 0 FILE COUNT
  299. FLST CON 0 FILE STATUS TO BE SET
  300. FRMT CON 0 FORMAT CODE
  301. OPARG CON 0 *OP=* ARGUMENT
  302. OPOF CON 0 *OP=O* PROCESSED FLAG
  303. OVWF CON 0 *OVWRITE* OPTION FLAG
  304. NOJF CON 1 *NOJT* TERMINATION FLAG
  305. ZODF CON 0 OPTICAL DISK CONTROL FILE FOUND FLAG
  306. SPACE 4,10
  307. ** PRESERVED REGISTER STORAGE LOCATIONS.
  308.  
  309.  
  310. SVA3 CON 0 SAVE (A3)
  311. SVB2 CON 0 SAVE (B2)
  312. SVB3 CON 0 SAVE (B3)
  313. SVB4 CON 0 SAVE (B4)
  314. SPACE 4,10
  315. ** *GETFNT* CONTROL WORD.
  316.  
  317.  
  318. GFCW VFD 12/MNF,6/0,18/0,2/0,1/1,3/4,18/FNTB
  319. SPACE 4,10
  320. ** COMMAND TABLE.
  321.  
  322.  
  323. TCSC BSS 0 FWA OF CONTROL WORD TABLE
  324. CLCC SCON 1,1,1,0,CPF,70B CLEAR
  325. OUCC SCON 1,1,1,0,COF,0B OUT
  326. OVCC SCON 0,1,1,1,CMS,244B OVWRITE
  327. OVCR SCON 0,1,1,1,CMS,254B OVWRITE RETURN
  328. RTCC SCON 0,1,1,1,CPF,70B RETURN
  329. RWCC SCON 0,1,1,1,0,50B REWIND
  330. SFCC SCON 0,1,1,1,CIF,0 SETFS
  331. UNCC SCON 0,1,1,1,CPF,60B UNLOAD
  332. TACW SPACE 4,10
  333. ** TACW - TABLE OF ARGUMENT CONTROL WORDS.
  334. *
  335. * THIS TABLE IS ADDRESSED USING THE OFFSET (*TACW*) FROM
  336. * THE CORRESPONDING ENTRY IN THE COMMAND
  337. * CONTROL WORD TABLE.
  338.  
  339.  
  340. TACW EQU *-TCSC TABLE OFFSET FROM *TCSC*
  341. ACON CAP,TOARG CLEAR
  342. ACON OAP,TOARG OUT
  343. ACON VAT,TOARG OVWRITE
  344. ACON VAT,TOARG OVWRITE RETURN
  345. ACON CAP,TOARG RETURN
  346. ACON 0,0 REWIND
  347. ACON SAP,TSARG SETFS
  348. ACON CAP,TOARG UNLOAD
  349. TDSP SPACE 4,10
  350. ** TDSP - *DSP* PARAMETER BLOCK.
  351.  
  352.  
  353. TDSP BSSZ 1
  354. VFD 42/0,18/FRFN RETURN JSN TO CALLER
  355. BSSZ 5
  356. TSFN SPACE 4,10
  357. ** TSFN - TABLE OF SPECIAL FILE NAMES.
  358. *
  359. *T 42/FILE NAME, 18/ 0
  360.  
  361.  
  362. TSFN BSS 0 START OF TABLE
  363. LOC 0
  364. OTPT CON 0LOUTPUT
  365. CON 0LPUNCH
  366. CON 0LPUNCHB
  367. CON 0LP8
  368. CON 0 END OF TABLE
  369. LOC *O
  370. SPACE 4,10
  371. MFILES TITLE COMMAND ENTRY POINTS.
  372. ** CLEAR.
  373. *
  374. * RETURN FILES ASSIGNED TO A JOB.
  375.  
  376.  
  377. CLEAR SB2 CLCC SET COMMAND WORD ADDRESS
  378. EQ MFP ENTER MAIN ROUTINE
  379. OUT SPACE 4,10
  380. ** OUT.
  381. * OUT(.../OP=X)
  382. *
  383. * RELEASE FILES ASSIGNED TO A JOB TO THE OUTPUT QUEUE.
  384. * THE OPTION SPECIFIED BY *X* IS DESCRIBED BELOW. IT
  385. * IS VALID ONLY DURING JOB TERMINATION PROCESSING.
  386. *
  387. * E PERFORM END-OF-JOB ROUTING.
  388. *
  389. * Q QUEUE FILE REGARDLESS OF USER
  390. * VALIDATION LIMITS.
  391.  
  392.  
  393. OUT SB2 OUCC SET COMMAND WORD ADDRESS
  394. EQ MFP ENTER MAIN LOOP
  395. OVWRITE SPACE 4,10
  396. ** OVWRITE.
  397. *
  398. * OVERWRITE FILES.
  399.  
  400.  
  401. OVWRITE SB2 OVCC SET COMMAND WORD ADDRESS
  402. EQ MFP ENTER MAIN ROUTINE
  403. SPACE 4,10
  404. ** RETURN.
  405. *
  406. * RETURN FILES ASSIGNED TO A JOB.
  407.  
  408.  
  409. RETURN SB2 RTCC SET COMMAND WORD ADDRESS
  410. EQ MFP ENTER MAIN ROUTINE
  411. SPACE 4,10
  412. ** REWIND.
  413. *
  414. * REWIND FILES ASSIGNED TO A JOB.
  415.  
  416.  
  417. REWIND SB2 RWCC SET COMMAND WORD ADDRESS
  418. EQ MFP ENTER MAIN ROUTINE
  419. SETFS SPACE 4,10
  420. ** SETFS.
  421. *
  422. * SET STATUS ON FILES ASSIGNED TO A JOB.
  423.  
  424.  
  425. SETFS SB2 SFCC SET COMMAND WORD ADDRESS
  426. EQ MFP ENTER MAIN ROUTINE
  427. SPACE 4,10
  428. ** UNLOAD.
  429. *
  430. * UNLOAD FILES ASSIGNED TO A JOB.
  431.  
  432.  
  433. UNLOAD SB2 UNCC SET COMMAND WORD ADDRESS
  434. * EQ MFP ENTER MAIN ROUTINE
  435. MFILES TITLE MAIN PROGRAM.
  436. MFILES SPACE 4,10
  437. ** RESERVED REGISTER USAGE.
  438. *
  439. * (A3) = ADDRESS OF FIRST FILE NAME ARGUMENT.
  440. * (B2) = COMMAND WORD ADDRESS.
  441. MFP SPACE 4,15
  442. ** MFP - MULTIPLE FILE PROCESSOR.
  443. *
  444. * ENTRY (B2) = COMMAND WORD ADDRESS.
  445. *
  446. * USES X - 4, 6, 7.
  447. * A - 4, 6, 7.
  448. *
  449. * CALLS IFC, PAF, PRS.
  450. *
  451. * MACROS ENDRUN, GETFNT, RECALL.
  452.  
  453.  
  454. MFP BSS 0 ENTRY
  455. RJ PRS PRESET
  456. SA4 GFCW PUT *GETFNT* CONTROL WORD IN FET
  457. BX6 X4
  458. SX7 B0
  459. SA6 FETC
  460. SA7 FNTB SET INITIAL *GETFNT* CALL
  461. MFP1 GETFNT FETX
  462. RJ PAF PROCESS ALL FILES
  463. ZR X1,MFP2 IF ALL FILES RETURNED IN BUFFER
  464. RECALL FETX
  465. EQ MFP1 GET ANOTHER BUFFER OF FNT ENTRIES
  466.  
  467. * TERMINATE JOB.
  468.  
  469. MFP2 SA4 FRMT GET FORMAT CODE
  470. SX4 X4-FMT3
  471. ZR X4,MFP3 IF FORMAT 3
  472. RJ IFC ISSUE FILE COUNT MESSAGE
  473. MFP3 ENDRUN
  474. TITLE SUBROUTINES.
  475. ABT SPACE 4,10
  476. ** ABT - ISSUE MESSAGE AND ABORT.
  477. *
  478. * ENTRY (X2) = MESSAGE ADDRESS.
  479. *
  480. * MACROS ABORT, MESSAGE.
  481.  
  482.  
  483. ABT BSS 0 ENTRY
  484. MESSAGE X2,3
  485. ABORT ABORT CONTROL POINT
  486. CFN SPACE 4,20
  487. ** CFN - CHECK FILE NAME FOR EXCLUSION.
  488. *
  489. * *CFN* CHECKS AN ARGUMENT LIST FOR THE PRESENCE OF THE FILE
  490. * NAME GIVEN BY AN FNT ENTRY. DEPENDING ON THE CONTROL
  491. * COMMAND, OTHER EXCLUSION TESTS MAY BE MADE.
  492. *
  493. * ENTRY (X1) = FNT ENTRY.
  494. * (X3) = FILE NAME.
  495. * (A1) = ADDRESS OF FNT ENTRY IN *GETFNT* BUFFER.
  496. * (A3) = ADDRESS OF FIRST ARGUMENT.
  497. * (B2) = COMMAND WORD ADDRESS.
  498. *
  499. * EXIT (X6) = 0 IF FILE TO BE EXCLUDED.
  500. * (X6) .NE. 0 IF FILE NOT TO BE EXCLUDED.
  501. *
  502. * USES X - 0, 4, 6.
  503. * A - 4.
  504. * B - 7.
  505. *
  506. * CALLS IRJ.
  507. *
  508. * NOTE EXCLUSION PROCESSOR SUBROUTINES MUST NOT DESTROY
  509. * REGISTERS A3, X3, B2, B3, OR B4.
  510.  
  511.  
  512. CFN SUBR ENTRY/EXIT
  513. SA4 B2 GET EXCLUSION PROCESSOR ADDRESS
  514. MX0 -18
  515. AX4 18
  516. BX4 -X0*X4
  517. ZR X4,CFN1 IF NO EXCLUSION PROCESSOR DEFINED
  518. SB7 X4+ SET PROCESSOR ADDRESS
  519. RJ IRJ EXECUTE EXCLUSION PROCESSOR
  520. ZR X6,CFNX IF FILE TO BE EXCLUDED
  521. CFN1 SA4 FRMT GET FORMAT CODE
  522. SB7 X4-FMT3
  523. SA4 A3+ READ FIRST FILE NAME ARGUMENT
  524. CFN2 ZR X4,CFN3 IF END OF ARGUMENT LIST
  525. BX6 X4-X3
  526. SA4 A4+B1 READ NEXT ARGUMENT
  527. NZ X6,CFN2 IF NOT FOUND
  528.  
  529. * THE FILE NAME WAS FOUND AS ONE OF THE ARGUMENTS SPECIFIED
  530. * (EITHER FORMAT 2 OR FORMAT 3 WAS USED). AN ADDITIONAL CHECK
  531. * IS REQUIRED TO DETERMINE IF THE FILE IS TO BE INCLUDED
  532. * OR EXCLUDED FROM PROCESSING. IF THE INCLUSION FORMAT
  533. * (FORMAT 3) WAS SPECIFIED, THE FILE WILL NOT BE EXCLUDED.
  534.  
  535. NZ B7,CFNX IF NOT FORMAT 3
  536. SX6 B1+ SET FILE NOT EXCLUDED
  537. EQ CFNX RETURN
  538.  
  539. * THE FILE NAME DID NOT MATCH ANY OF THE ARGUMENTS SPECIFIED.
  540. * A CHECK MUST BE MADE TO DETERMINE IF THE FILE SHOULD
  541. * BE EXCLUDED OR INCLUDED BY THE PROCESSING TYPE SPECIFIED.
  542. * IF THE INCLUSION FORMAT (FORMAT 3) WAS SPECIFIED, THE
  543. * FILE WILL BE EXCLUDED.
  544.  
  545. CFN3 NZ B7,CFNX IF NOT FORMAT 3
  546. SX6 B0+ SET FILE EXCLUDED
  547. EQ CFNX RETURN
  548. CIF SPACE 4,10
  549. ** CIF - CHECK FOR INPUT* FILE.
  550. *
  551. * ENTRY (X1) = FNT ENTRY.
  552. *
  553. * EXIT (X6) = 0 IF FILE IS INPUT*.
  554. *
  555. * USES X - 0, 4, 6, 7.
  556. * A - 4.
  557.  
  558.  
  559. CIF SUBR ENTRY/EXIT
  560. SA4 =6LINPUT*
  561. MX0 42
  562. BX7 X0*X1
  563. BX6 X4-X7
  564. EQ CIFX RETURN
  565. CMS SPACE 4,15
  566. ** CMS - CHECK FOR MASS STORAGE AND READ ONLY FILE.
  567. *
  568. * ENTRY (X1) = FNT ENTRY.
  569. * (A1) = ADDRESS OF FNT ENTRY IN *GETFNT* BUFFER.
  570. * (X3) = FILE NAME.
  571. * (A3) = ADDRESS OF FIRST ARGUMENT.
  572. *
  573. * EXIT (X6) = 0 IF FILE TO BE EXCLUDED.
  574. *
  575. * USES X - 0, 1, 4, 6.
  576. * A - 4.
  577. * B - 2, 3, 5.
  578. *
  579. * CALLS CIF, RSR, SNM, SVR.
  580. *
  581. * MACROS MESSAGE.
  582.  
  583.  
  584. CMS SUBR ENTRY/EXIT
  585. MX0 2
  586. LX0 14-59
  587. BX6 X0*X1
  588. SB5 -CMSA MESSAGE TEXT
  589. NZ X6,CMS1 IF FILE NOT MASS STORAGE
  590. RJ CIF
  591. ZR X6,CMSX IF INPUT* FILE
  592. SA4 A1+B1 CHECK FOR WRITE MODE
  593. MX0 -4
  594. SX6 B1+ SET FILE INCLUDED
  595. LX4 -4
  596. BX4 -X0*X4
  597. SB5 X4
  598. EQ B5,B1,CMSX IF FILE IN WRITE MODE
  599. SB5 -CMSB MESSAGE TEXT
  600.  
  601. * SEARCH ARGUMENT LIST FOR MATCHING FILE NAME TO DETERMINE
  602. * IF WARNING MESSAGE SHOULD BE ISSUED.
  603.  
  604. CMS1 SA4 A3+ READ FIRST FILE NAME ARGUMENT
  605. CMS2 ZR X4,CMS3 IF END OF ARGUMENT LIST
  606. BX0 X4-X3
  607. SA4 A4+B1 READ NEXT ARGUMENT
  608. NZ X0,CMS2 IF NOT FOUND
  609. SA4 FRMT GET FORMAT CODE
  610. SX4 X4-FMT3
  611. NZ X4,CMS3 IF NOT FORMAT 3
  612.  
  613. * ISSUE WARNING MESSAGE AND EXCLUDE FILE.
  614.  
  615. RJ SVR SAVE REGISTERS
  616. SB2 1R+ SET SEARCH CHARACTER
  617. SB3 CMSC MESSAGE ASSEMBLY BUFFER
  618. MX0 42
  619. BX1 X0*X1 FILE NAME
  620. RJ SNM SET NAME IN MESSAGE
  621. MESSAGE CMSC,3,R
  622. RJ RSR RESTORE REGISTERS
  623. CMS3 SX6 B0+ EXCLUDE FILE
  624. EQ CMSX RETURN
  625.  
  626. CMSA DATA C* +++++++ NOT ON MASS STORAGE.*
  627. CMSB DATA C* +++++++ NOT IN WRITE MODE.*
  628. CMSC BSS 4 ASSEMBLY BUFFER
  629. COC SPACE 4,10
  630. ** COC - CHECK FOR OPTICAL CONTROL FILE *ZZZZZOD*.
  631. *
  632. * ENTRY (X1) = FNT ENTRY.
  633. *
  634. * EXIT (X6) = 0 IF FILE IS ZZZZZOD.
  635. *
  636. * USES X - 0, 4, 6, 7.
  637. * A - 4.
  638.  
  639.  
  640. COC SUBR ENTRY/EXIT
  641. MX0 2
  642. LX0 14-59
  643. BX6 X0*X1
  644. NZ X6,COCX IF FILE NOT MASS STORAGE
  645. SA4 =7LZZZZZOD
  646. MX0 42
  647. BX7 X0*X1
  648. BX6 X4-X7
  649. EQ COCX RETURN
  650. COF SPACE 4,20
  651. ** COF - CHECK IF OUTPUT FILE.
  652. *
  653. * *COF* CHECKS TO SEE IF THE GIVEN FILE SHOULD BE
  654. * ROUTED TO THE OUTPUT QUEUE. THE CRITERIA USED
  655. * FOR SELECTION ARE -
  656. *
  657. * (1) FILE TYPE IS *QFFT*.
  658. * (2) FILE IS A LOCAL FILE (FILE TYPE *LOFT*) AND
  659. * HAS A SPECIAL NAME, *OUTPUT*, *PUNCH*, *P8*,
  660. * OR *PUNCHB*.
  661. *
  662. * ENTRY (X1) = FNT ENTRY.
  663. * (X3) = FILE NAME.
  664. *
  665. * EXIT (X6) = NONZERO IF FILE TO BE ROUTED TO QUEUE.
  666. *
  667. * USES X - 4, 6, 7.
  668. * A - 4.
  669. * B - 6.
  670.  
  671.  
  672. COF SUBR ENTRY/EXIT
  673.  
  674. * CHECK FILE TYPE.
  675.  
  676. BX4 X1 CHECK FNT PARAMETERS
  677. MX6 -2
  678. AX4 13
  679. BX6 -X6*X4
  680. NZ X6,COF3 IF NOT MASS STORAGE FILE
  681. BX4 X1 CHECK FILE TYPE
  682. MX6 -6
  683. AX4 6
  684. BX7 -X6*X4
  685. SB6 X7-QFFT
  686. ZR B6,COF1.1 IF QUEUED FILE
  687. SB6 X7-LOFT
  688. NZ B6,COF3 IF NOT LOCAL FILE
  689. SA4 NOJF CHECK TERMINATION OPTION FLAG
  690. ZR X4,COF3 IF NOT ROUTING *SPECIAL NAME* LOCAL FILES
  691.  
  692. * CHECK FOR SPECIAL FILE NAMES.
  693.  
  694. COF1 SA4 TSFN+B6 READ TABLE ENTRY
  695. ZR X4,COF3 IF END OF TABLE
  696. BX7 X4-X3 COMPARE FILE NAMES
  697. SB6 B6+B1 ADVANCE TABLE INDEX
  698. NZ X7,COF1 IF NO MATCH
  699.  
  700. * PROCESS END-OF-JOB FILE ROUTING.
  701.  
  702. COF1.1 SA4 EOJS CHECK FOR END-OF-JOB PROCESSING
  703. ZR X4,COF2 IF NOT END-OF-JOB
  704. BX7 -X6*X1 CHECK FILE STATUS
  705. SX7 X7-SOST
  706. ZR X7,COF2 IF *SOST* STATUS
  707. SA4 NOJF CHECK TERMINATION OPTION FLAG
  708. ZR X4,COF2 IF ROUTING ANY QUEUED FILE
  709. SA4 TSFN+OTPT CHECK FILE NAME
  710. BX7 X3-X4
  711. NZ X7,COF2 IF FILE NAME .NE. *OUTPUT*
  712. BX4 X1 CHECK IF *OUTPUT* IS LOCKED
  713. LX4 59-12
  714. PL X4,COF3 IF *OUTPUT* IS NOT LOCKED
  715.  
  716. * RETURN STATUS TO ROUTE FILE.
  717.  
  718. COF2 SX6 B1+
  719. EQ COFX RETURN
  720.  
  721. * RETURN STATUS TO IGNORE FILE.
  722.  
  723. COF3 SX6 B0+
  724. EQ COFX RETURN
  725.  
  726. CPF SPACE 4,10
  727. ** CPF - CHECK FOR PROTECTED FILE.
  728. *
  729. * ENTRY (X1) = FNT ENTRY.
  730. * (X3) = FILE NAME.
  731. * (A3) = ADDRESS OF FIRST ARGUMENT.
  732. *
  733. * EXIT (X6) = 0 IF PROTECTED FILE TO BE EXCLUDED.
  734. *
  735. * USES X - 4, 6, 7.
  736. * A - 4, 7.
  737. *
  738. * CALLS COC, CIF, RSR, SVR.
  739. *
  740. * MACROS FILINFO.
  741.  
  742.  
  743. CPF5 SX7 X4+ SET CONTROL FILE FOUND FLAG IF *OP=O*
  744. SA7 ZODF
  745.  
  746. CPF SUBR ENTRY/EXIT
  747. RJ CIF
  748. ZR X6,CPFX IF INPUT* FILE
  749. RJ COC CHECK FOR OPTICAL CONTROL FILE
  750. SA4 OPOF
  751. ZR X6,CPF5 IF OPTICAL CONTROL FILE
  752. NZ X4,CPF4 IF *OP=O* SPECIFIED
  753. MX4 -6 CHECK IF *CBST*, *CKST* OR *NDST* STATUS
  754. BX4 -X4*X1
  755. SX6 X4-CBST
  756. ZR X6,CPF1 IF CHECKPOINT FILE
  757. SX6 X4-CKST
  758. ZR X6,CPF1 IF CHECKPOINT FILE
  759. SX6 X4-NDST
  760. NZ X6,CPFX IF NOT NO-AUTO-DROP STATUS
  761.  
  762. * IT IS A PROTECTED FILE. SEARCH THE ARGUMENT LIST FOR
  763. * MATCHING FILE NAME. IF A MATCH IS FOUND AND INCLUSION
  764. * PROCESSING (FORMAT 3) HAS BEEN SELECTED, RETURN (X6)
  765. * NON-ZERO SO THAT THE FILE WILL BE PROCESSED. OTHERWISE,
  766. * RETURN (X6) = 0 SO THAT THE FILE WILL BE EXCLUDED.
  767.  
  768. CPF1 SA4 A3+ READ FIRST FILE NAME ARGUMENT
  769. CPF2 ZR X4,CPFX IF END OF ARGUMENT LIST
  770. BX7 X4-X3
  771. SA4 A4+B1 READ NEXT ARGUMENT
  772. NZ X7,CPF2 IF NOT FOUND
  773. SA4 FRMT GET FORMAT CODE
  774. SX4 X4-FMT3 CHECK FOR FORMAT 3
  775. CPF3 NZ X4,CPFX IF FILE TO BE EXCLUDED
  776. SX6 B1+ PROCESS THE FILE
  777. EQ CPFX RETURN
  778.  
  779. * *OP=O* SPECIFIED - CHECK FOR OPTICAL DISK FILE.
  780.  
  781. CPF4 SA4 CPFA SET UP *FILINFO* PARAMETER BLOCK
  782. MX6 42
  783. BX7 X6*X1
  784. BX6 -X6*X4
  785. BX7 X6+X7
  786. SA7 A4+
  787. RJ SVR SAVE REGISTERS
  788. FILINFO CPFA GET FILE INFORMATION
  789. RJ RSR RESTORE REGISTERS
  790. SA4 CPFA+1
  791. BX6 X6-X6 SET TO EXCLUDE FILE IF NOT OPTICAL DISK
  792. AX4 48
  793. SX4 X4-2ROD
  794. EQ CPF3 EXCLUDE FILE UNLESS ON OPTICAL DISK
  795.  
  796. CPFA VFD 42/0,6/5,12/1 *FILINFO* PARAMETER BLOCK
  797. BSSZ 5
  798. GNF SPACE 4,20
  799. ** GNF - GET NONBUSY FET.
  800. *
  801. * *GNF* DETERMINES WHETHER ANY FET IN THE SET OF FETS IS
  802. * CURRENTLY BUSY WITH THE GIVEN FILE AND IF NONE IS, RETURNS
  803. * THE ADDRESS OF A NONBUSY FET.
  804. *
  805. * ENTRY (X3) = FILE NAME TO LOOK FOR.
  806. *
  807. * EXIT (X2) = 0 IF A FET IS BUSY WITH THE FILE.
  808. * (X2) = ADDRESS OF A NONBUSY FET OTHERWISE.
  809. *
  810. * USES X - 0, 1, 2.
  811. * A - 1.
  812. * B - 5, 7.
  813. *
  814. * MACROS RECALL.
  815.  
  816.  
  817. GNF2 SX2 A1+ SAVE ADDRESS OF NONBUSY FET
  818. NZ B5,GNFX IF EXCLUSION FORM
  819. GNF3 SA1 A1+FETL
  820. SB7 A1-FETX-1
  821. NG B7,GNF1 IF NOT PAST END OF FETS
  822. NZ X2,GNFX IF NONBUSY FET FOUND
  823. RECALL FETS
  824.  
  825. GNF SUBR ENTRY/EXIT
  826. SA1 FRMT GET FORMAT CODE
  827. SB5 X1-FMT3
  828. SA1 FETS
  829. MX0 42
  830. BX2 X2-X2
  831. GNF1 LX1 59-0
  832. NG X1,GNF2 IF NOT BUSY
  833. LX1 1 RESTORE X1
  834. NZ B5,GNF3 IF EXCLUSION FORM
  835. BX1 X0*X1
  836. BX1 X1-X3
  837. NZ X1,GNF3 IF NOT A FILE NAME MATCH
  838. SX2 B0+
  839. EQ GNFX RETURN
  840. IFC SPACE 4,15
  841. ** IFC - ISSUE FILE COUNT MESSAGE.
  842. *
  843. * ENTRY (FICT) = FILE COUNT.
  844. *
  845. * EXIT MESSAGE ISSUED.
  846. *
  847. * USES X - 1, 2, 6.
  848. * A - 1, 6.
  849. *
  850. * CALLS CDD.
  851. *
  852. * MACROS MESSAGE.
  853.  
  854.  
  855. IFC SUBR ENTRY/EXIT
  856. SA1 FICT GET FILE COUNT
  857. SX2 IFCA ASSUME NO FILES
  858. ZR X1,IFC1 IF NO FILES PROCESSED
  859. SX6 X1-1 CHECK FILE COUNT
  860. SX2 IFCB
  861. ZR X6,IFC1 IF ONE FILE PROCESSED
  862. RJ CDD CONVERT TO DECIMAL
  863. SA1 IFCC MERGE FILE COUNT WITH MESSAGE
  864. MX2 24
  865. LX6 36
  866. BX1 -X2*X1
  867. BX6 X2*X6
  868. BX6 X6+X1
  869. SA6 A1
  870. SX2 A1 SET MESSAGE ADDRESS
  871. IFC1 MESSAGE X2,3 ISSUE DAYFILE MESSAGE
  872. EQ IFCX RETURN
  873.  
  874. IFCA DATA C* NO FILES PROCESSED.*
  875. IFCB DATA C* 1 FILE PROCESSED.*
  876. IFCC DATA C* 000 FILES PROCESSED.*
  877. IRJ SPACE 4,15
  878. ** IRJ - INDEX RETURN JUMP.
  879. *
  880. * EXECUTES A RETURN JUMP TO (B7).
  881. *
  882. * ENTRY (B7) = BRANCH ADDRESS.
  883. *
  884. * EXIT TO (B7)+1.
  885. * JUMP INSTRUCTION TO RETURN LOCATION IN ((B7)).
  886. *
  887. * USES X - 5, 6.
  888. * A - 5, 6.
  889.  
  890.  
  891. IRJ SUBR ENTRY/EXIT
  892. SA5 IRJ READ RETURN INSTRUCTION
  893. BX6 X5 SET RETURN IN CALLED ROUTINE
  894. SA6 B7
  895. JP B7+1 ENTER CALLED ROUTINE
  896. PAF SPACE 4,20
  897. ** PAF - PROCESS ALL FILES.
  898. *
  899. * *PAF* REQUESTS AN OPERATION FOR EACH FILE IN THE SET OF
  900. * FNT ENTRIES EXCEPT THOSE THAT ARE EXCLUDED.
  901. *
  902. * ENTRY (A3) = ADDRESS OF THE FIRST ARGUMENT.
  903. * (B2) = COMMAND WORD ADDRESS.
  904. *
  905. * EXIT (X1) = 0 IF ALL FILES RETURNED IN THE BUFFER.
  906. *
  907. * USES X - 0, 1, 3.
  908. * A - 1, 3.
  909. * B - 3, 4.
  910. *
  911. * CALLS CFN, POF.
  912.  
  913.  
  914. PAF3 SA1 ZODF
  915. ZR X1,PAFX IF NOT PROCESSING OPTICAL CONTROL FILE
  916. SA3 =7LZZZZZOD
  917. RJ POF PROCESS ONE FILE
  918. * SX1 0 (*POF* EXIT CONDITION)
  919.  
  920. PAF SUBR ENTRY/EXIT
  921. SB4 FNTBL-1 END OF *GETFNT* BUFFER
  922. SB3 B1
  923. PAF1 SA1 B3+FNTB GET FNT ENTRY
  924. MX0 42
  925. BX3 X0*X1
  926. ZR X1,PAF3 IF END OF ENTRIES
  927. RJ CFN CHECK FILE NAME FOR EXCLUSION
  928. ZR X6,PAF2 IF FILE TO BE EXCLUDED
  929. RJ POF PROCESS ONE FILE
  930. PAF2 SB3 B3+2
  931. NE B3,B4,PAF1 IF MORE FNT ENTRIES
  932. SX1 B1+
  933. EQ PAFX RETURN
  934. POF SPACE 4,20
  935. ** POF - PROCESS ONE FILE.
  936. *
  937. * *PAF* REQUESTS AN OPERATION FOR ONE FILE.
  938. *
  939. * ENTRY (X3) = NAME OF FILE TO BE PROCESSED.
  940. * (B2) = COMMAND WORD ADDRESS.
  941. *
  942. * EXIT SPECIFIED FILE PROCESSED AS REQUESTED.
  943. * (X1) = 0.
  944. *
  945. * USES X - 0, 1, 2, 4, 6, 7.
  946. * A - 1, 4, 6, 7.
  947. * B - 2, 3, 5, 6.
  948. *
  949. * CALLS CIO=, GNF, RSR, SNM, SVR.
  950. *
  951. * MACROS MESSAGE, ROUTE, SETFS.
  952.  
  953.  
  954. POF SUBR ENTRY/EXIT
  955. SB6 B2-OUCC
  956. ZR B6,POF3 IF *OUT* COMMAND
  957. SA4 B2 GET *CIO* CODE
  958. SX7 X4
  959. RJ GNF GET NONBUSY FET
  960. ZR X2,POF5 IF FILE ALREADY DONE
  961. SX4 B1
  962. BX6 X3+X4
  963. SA6 X2+
  964. SB6 B2-SFCC
  965. ZR B6,POF2 IF *SETFS* COMMAND
  966. SB6 B2-OVCC
  967. NZ B6,POF1 IF NOT *OVWRITE* COMMAND
  968. SA1 OVWF OPTIONAL PARAMETER INDICATOR
  969. LX1 18-0
  970. BX2 X1+X2 COMBINE OPTIONAL PARAMETER WITH FILE NAME
  971.  
  972. * PROCESS *CIO* FUNCTION.
  973.  
  974. POF1 RJ CIO= MAKE REQUEST
  975. EQ POF4 INCREMENT FILE COUNT
  976.  
  977. * PROCESS *LFM* REQUEST.
  978.  
  979. POF2 SA1 FLST SET FILE STATUS
  980. SETFS X2,X1
  981. EQ POF4 INCREMENT FILE COUNT
  982.  
  983. * PROCESS *DSP* FUNCTION.
  984.  
  985. POF3 BX7 X3 SET FILE NAME
  986. MX0 42
  987. BX1 X0*X7
  988. SA7 TDSP
  989. RJ SVR SAVE REGISTERS
  990. SB2 1R= SET SCAN PARAMETER
  991. SB5 -POFA SET STENCIL ADDRESS
  992. SB3 POFB SET ASSEMBLY BUFFER ADDRESS
  993. RJ SNM SET NAME IN MESSAGE
  994. ROUTE TDSP,RECALL
  995. MX0 24
  996. SA1 TDSP GET JSN RETURNED
  997. BX1 X0*X1
  998. SB2 1R+ SET SCAN PARAMETER
  999. SB5 POFB SET *POFB* AS ASSEMBLY BUFFER
  1000. RJ SNM SET NAME IN MESSAGE
  1001. MESSAGE POFB,0,RECALL SEND MESSAGE TO USER DAYFILE
  1002. RJ RSR RESTORE REGISTERS
  1003. POF4 SA1 FICT INCREMENT FILE COUNT
  1004. SX6 X1+B1
  1005. SA6 A1
  1006. POF5 SX1 B0+
  1007. EQ POFX RETURN
  1008.  
  1009. POFA DATA C* ======= ROUTED. JSN IS ++++. *
  1010. POFB DATA C* ======= ROUTED. JSN IS ++++. *
  1011. RSR SPACE 4,10
  1012. ** RSR - RESTORE RESERVED REGISTERS.
  1013. *
  1014. * RESTORES THE CONTENTS OF X3, A3, B2, B3, AND B4.
  1015. *
  1016. * ENTRY (SVA3) = (A3).
  1017. * ((SVA3)) = (X3).
  1018. * (SVB2) = (B2).
  1019. * (SVB4) = (B4).
  1020. * (SVB3) = (B3).
  1021. *
  1022. * USES X - 3.
  1023. * A - 3.
  1024. * B - 2, 3, 4.
  1025.  
  1026.  
  1027. RSR SUBR ENTRY/EXIT
  1028. SA3 SVB4 RESTORE (B4)
  1029. SB4 X3
  1030. SA3 A3-B1 RESTORE (B3)
  1031. SB3 X3
  1032. SA3 A3-B1 RESTORE (B2)
  1033. SB2 X3
  1034. SA3 A3-B1 READ A3
  1035. SA3 X3+ RESTORE (A3) AND (X3)
  1036. EQ RSRX RETURN
  1037. SVR SPACE 4,15
  1038. ** SVR - SAVE RESERVED REGISTERS.
  1039. *
  1040. * SAVES RESERVED REGISTERS A3, X3, B2, B3, AND B4.
  1041. * THESE REGISTERS MAY LATER BE RESTORED BY
  1042. * EXECUTING *RSR*. NOTE THAT X3 IS NOT SAVED
  1043. * DIRECTLY, BUT IS AUTOMATICALLY RELOADED WHEN
  1044. * A3 IS RESTORED.
  1045. *
  1046. * EXIT (SVA3) = (A3).
  1047. * (SVB2) = (B2).
  1048. * (SVB4) = (B4).
  1049. * (SVB3) = (B3).
  1050. *
  1051. * USES X - 6.
  1052. * A - 6.
  1053.  
  1054.  
  1055. SVR SUBR ENTRY/EXIT
  1056. SX6 A3 SAVE (A3)
  1057. SA6 SVA3
  1058. SX6 B2 SAVE (B2)
  1059. SA6 A6+B1
  1060. SX6 B3+ SAVE (B3)
  1061. SA6 A6+B1
  1062. SX6 B4 SAVE (B4)
  1063. SA6 A6+B1
  1064. EQ SVRX RETURN
  1065. SPACE 4,10
  1066. * COMMON DECKS.
  1067.  
  1068.  
  1069. *CALL COMCCDD
  1070. *CALL COMCCIO
  1071. *CALL COMCCPM
  1072. *CALL COMCLFM
  1073. *CALL COMCSNM
  1074. *CALL COMCSYS
  1075. BUFFERS SPACE 4,10
  1076. ** BUFFER ASSIGNMENTS.
  1077.  
  1078.  
  1079. USE BUFFERS
  1080.  
  1081. PSBF EQU * PSEUDO BUFFER FOR FETS
  1082. FNTB EQU PSBF+PSBFL BUFFER FOR *GETFNT*
  1083. RFL= EQU FNTB+FNTBL
  1084. NPC= EQU 0 FORCE OPERATING SYSTEM PARAMETER FORMAT
  1085. SSM= EQU 0 DECLARE *SSM=* ENTRY POINT
  1086.  
  1087. ERRNG JTFL*100B-RFL= IF OVERFLOW MAXIMUM JOB TERMINATION FL
  1088. MFILES TITLE OVERLAID PRESET.
  1089. PRS SPACE 4,30
  1090. ** PRS - PRESET.
  1091. *
  1092. * *PRS* DETERMINES THE FORMAT OF THE CALLING CONTROL
  1093. * COMMAND, SETS THE ADDRESS OF THE FIRST ARGUMENT
  1094. * TO PROCESS AND CHECKS FOR THE PRESENCE OF NONZERO
  1095. * SEPARATORS (= OR /).
  1096. *
  1097. * ENTRY (B2) = COMMAND WORD ADDRESS.
  1098. *
  1099. * EXIT (X3) = FIRST ARGUMENT.
  1100. * (A3) = ADDRESS OF FIRST ARGUMENT TO PROCESS.
  1101. * (FRMT) = COMMAND FORMAT CODE.
  1102. * TO *ABT* IF ARGUMENT ERROR.
  1103. *
  1104. * USES X - 0, 1, 2, 3, 4, 5, 6.
  1105. * A - 1, 3, 4, 6.
  1106. * B - 1, 3, 4, 5, 6.
  1107. *
  1108. * CALLS MOL, POL.
  1109. *
  1110. * ERROR TO *ABT*.
  1111.  
  1112.  
  1113. PRS SUBR ENTRY/EXIT
  1114. SB1 1 SET CONSTANT B1=1
  1115. RJ MOL MOVE */* OPTION LIST
  1116. SX2 =C* ERROR IN ARGUMENTS.*
  1117. SB4 B0 INITIALIZE FORMAT CODE TO 0
  1118. ERRNZ FMT0 ADJUST IF VALUE CHANGES
  1119. MX0 42
  1120. SA3 ARGR GET FIRST ARGUMENT
  1121. SA4 ACTR GET ARGUMENT COUNT
  1122. SB3 X4+
  1123. ZR B3,PRS1 IF NO ARGUMENTS - FORMAT 0
  1124. SB4 FMT3
  1125. SA4 PRSA GET SPECIAL ARGUMENT VALUE (*)
  1126. BX4 X3-X4
  1127. NZ X4,PRS1 IF ARGUMENT NOT * - FORMAT 3
  1128. SA3 A3+B1
  1129. SB3 B3-B1 ADJUST ARGUMENT COUNT FOR *
  1130. SB4 B1
  1131. ERRNZ FMT1-1 ADJUST IF VALUE CHANGES
  1132. ZR B3,PRS1 IF ONLY * - FORMAT 1
  1133. SB4 B4+B1 SET FORMAT CODE TO 2
  1134. ERRNZ FMT2-FMT1-1 ADJUST IF VALUE CHANGES
  1135.  
  1136. * CHECK COMMAND FORMAT VALIDITY.
  1137.  
  1138. PRS1 SA1 B2 GET CONTROL WORD
  1139. LX4 X1,B4
  1140. PL X4,ABT IF INCORRECT COMMAND FORMAT
  1141.  
  1142. * CHECK SEPARATORS OF ARGUMENTS.
  1143.  
  1144. SA1 A3 GET FIRST ARGUMENT
  1145. SB5 B0
  1146. SX6 B4+ SAVE FORMAT CODE
  1147. SA6 FRMT
  1148. SB6 B4-FMT3
  1149. NZ B6,PRS2 IF NOT FORMAT 3
  1150. MX6 6
  1151. BX4 X6*X1
  1152. SX5 1R*
  1153. LX4 6
  1154. BX4 X4-X5
  1155. ZR X4,ABT IF FIRST CHARACTER OF FILENAME IS *
  1156. PRS2 EQ B5,B3,PRS3 IF END OF ARGUMENTS
  1157. BX4 -X0*X1
  1158. ZR X1,ABT IF BLANK ARGUMENT
  1159. NZ X4,ABT IF SEPARATOR IS = OR /
  1160. SA1 A1+B1
  1161. SB5 B5+B1
  1162. EQ PRS2 CHECK NEXT ARGUMENT
  1163.  
  1164. PRS3 NZ X1,ABT IF NOT ZERO LAST WORD
  1165. RJ POL PROCESS */* OPTION LIST
  1166. EQ PRSX RETURN
  1167.  
  1168. PRSA DATA 0L* SPECIAL ARGUMENT
  1169. MFILES TITLE OVERLAID PRESET SUBROUTINES.
  1170. MOL SPACE 4,20
  1171. ** MOL - MOVE */* OPTION LIST.
  1172. *
  1173. * MOVES THE OPTION LIST DELIMITED BY THE */* SEPARATOR
  1174. * TO A SEPARATE OPTION LIST AND CLEARS IT FROM THE
  1175. * ORIGINAL COMMAND PARAMETER LIST. THE PARAMETER
  1176. * COUNT OF THE REMAINING COMMAND PARAMETER LIST
  1177. * IS ADJUSTED TO REFLECT THE NEW PARAMETER COUNT.
  1178. *
  1179. * ENTRY (B2) = COMMAND WORD ADDRESS.
  1180. *
  1181. * EXIT (CSOC) = COUNT OF */* OPTION LIST PARAMETERS.
  1182. * (TOPS) = */* OPTION LIST.
  1183. * (ACTR) = ADJUSTED PARAMETER COUNT.
  1184. *
  1185. * ERROR TO *ABT* IF NO FILE STATUS SPECIFIED ON *SETFS*.
  1186. *
  1187. * USES X - 0, 1, 2, 6, 7.
  1188. * A - 1, 6, 7.
  1189. * B - 4, 5, 6, 7.
  1190.  
  1191.  
  1192. MOL SUBR ENTRY/EXIT
  1193. SA1 ACTR GET ARGUMENT COUNT
  1194. SB6 B0 CLEAR INDEX
  1195. MX0 42 SET PARAMETER MASK
  1196. SB7 X1+ (B7) = ARGUMENT COUNT
  1197. ZR B7,MOLX IF NO ARGUMENTS, RETURN
  1198.  
  1199. * SEARCH FOR */* DELIMITER IN PARAMETER LIST.
  1200.  
  1201. MOL1 SA1 ARGR+B6 READ ARGUMENT
  1202. SB6 B6+B1 COUNT ARGUMENT
  1203. BX6 -X0*X1 CHECK SEPARATOR
  1204. SX6 X6-1R/
  1205. ZR X6,MOL2 IF */*
  1206. NE B6,B7,MOL1 IF NOT END OF PARAMETER LIST
  1207. SX2 =C* FILE STATUS NOT SPECIFIED.*
  1208. SB5 B2-SFCC
  1209. ZR B5,ABT IF *SETFS* COMMAND
  1210. EQ MOLX RETURN
  1211.  
  1212. * ADJUST PARAMETER COUNT.
  1213.  
  1214. MOL2 BX7 X0*X1 CLEAR */* FROM PARAMETER
  1215. SA7 A1
  1216. SA1 ACTR READ PARAMETER COUNT WORD
  1217. SX6 B6 SET NEW PARAMETER COUNT
  1218. BX1 X0*X1
  1219. NZ X7,MOL3 IF NOT NOW A NULL LAST PARAMETER
  1220. SX6 X6-1 DECREMENT PARAMETER COUNT
  1221. MOL3 BX6 X1+X6 STORE NEW PARAMETER COUNT
  1222. SA6 A1+
  1223. SX7 B7-B6 SET OPTION LIST ARGUMENT COUNT
  1224. SA7 CSOC
  1225. SX7 B0 CLEAR (X7)
  1226. SB4 B0 CLEAR INDEX
  1227.  
  1228. * MOVE OPTIONS TO SEPARATE LIST.
  1229.  
  1230. MOL4 SA1 ARGR+B6 READ OPTION FROM PARAMETER LIST
  1231. SB6 B6+B1 COUNT OPTION
  1232. BX6 X1
  1233. SA6 TOPS+B4 STORE OPTION IN OPTION LIST
  1234. SA7 A1 CLEAR OPTION FROM PARAMETER LIST
  1235. SB4 B4+B1
  1236. NE B6,B7,MOL4 IF NOT END OF LIST
  1237. EQ MOLX RETURN
  1238. CAP SPACE 4,25
  1239. ** CAP - *CLEAR* ARGUMENT PROCESSOR.
  1240. *
  1241. * PROCESSES THE OPTIONAL ARGUMENTS FOR THE *CLEAR*,
  1242. * *RETURN* AND *UNLOAD* COMMANDS. *OP=O* ALLOWED
  1243. * ONLY ON FORMAT 0 OR 1 FOR THESE COMMANDS.
  1244. *
  1245. * ENTRY (OPARG) = *OP=* ARGUMENT.
  1246. * (B4) = FORMAT MODE.
  1247. *
  1248. * EXIT (OPOF) = NON-ZERO IF PROCESSING ONLY OPTICAL DISK
  1249. * FILES AND THE *ZZZZZOD* FILE (*O* OPTION).
  1250. *
  1251. * ERROR TO *ABT* IF INCORRECT ARGUMENT OR FORMAT.
  1252. *
  1253. * USES X - 1, 2, 6.
  1254. * A - 1, 6.
  1255.  
  1256.  
  1257. CAP SUBR ENTRY/EXIT
  1258. SX2 =C+ INCORRECT */* OPTION.+ PRESET ERROR MESSAGE
  1259. SA1 OPARG READ ARGUMENT
  1260. SX6 1RO CLEAR, RETURN OR UNLOAD W/OP=O.
  1261. LX1 6
  1262. BX1 X6-X1
  1263. NZ X1,ABT IF NOT *O* OPTION
  1264.  
  1265. * PROCESS *O* OPTION.
  1266.  
  1267. GT B4,B1,ABT IF NOT FORMAT 0 OR 1.
  1268. SA6 OPOF
  1269. EQ CAPX RETURN
  1270. OAP SPACE 4,25
  1271. ** OAP - *OUT* ARGUMENT PROCESSOR.
  1272. *
  1273. * PROCESSES THE OPTIONAL ARGUMENTS FOR THE *OUT*
  1274. * COMMAND.
  1275. *
  1276. * ENTRY (OPARG) = *OP=* ARGUMENT.
  1277. *
  1278. * EXIT (EOJS) = END-OF-JOB STATUS IF PROCESSING
  1279. * *E* OPTION.
  1280. *
  1281. * ERROR TO *ABT* IF INCORRECT ARGUMENT.
  1282. *
  1283. * USES X - 1, 2, 4, 6.
  1284. * A - 1, 4, 6.
  1285. *
  1286. * MACROS GETEOJS.
  1287.  
  1288.  
  1289. OAP SUBR ENTRY/EXIT
  1290. SX2 =C+ INCORRECT */* OPTION.+ PRESET ERROR MESSAGE
  1291. ZR B4,ABT IF FORMAT CODE = 0
  1292. SA1 OPARG READ ARGUMENT
  1293. SX6 1RE
  1294. LX1 6
  1295. BX6 X6-X1
  1296. NZ X6,ABT IF NOT *E* OPTION
  1297.  
  1298. * CHECK FOR JOB TERMINATION IN PROGRESS.
  1299.  
  1300. GETEOJS OAPA READ END-OF-JOB STATUS
  1301. SA4 OAPA READ REPLY WORD
  1302. SX2 =C+ INCORRECT */* OPTION.+
  1303. SX6 X4-100B CHECK FOR TERMINATION IN PROGRESS
  1304. NG X6,ABT IF TERMINATION NOT IN PROGRESS
  1305. MX2 -3 MASK FOR TERMINATION DISPOSITION
  1306. BX2 -X2*X4
  1307. SX6 X2-NOJT
  1308. SA6 NOJF SET *NOJT* TERMINATION OPTION
  1309.  
  1310. * PROCESS *E* OPTION.
  1311.  
  1312. SX6 X4+ SET END-OF-JOB PROCESSING STATUS
  1313. SA6 EOJS
  1314. EQ OAPX RETURN
  1315.  
  1316. OAPA CON 0 *GETEOJS* REPLY WORD
  1317. SAP SPACE 4,15
  1318. ** SAP - *SETFS* ARGUMENT PROCESSOR.
  1319. *
  1320. * PROCESSES THE ARGUMENTS FOR THE *SETFS* COMMAND.
  1321. *
  1322. * ENTRY (FLST) = SPECIFIED FILE STATUS (DISPLAY CODE).
  1323. *
  1324. * EXIT (FLST) = FILE STATUS (BINARY).
  1325. *
  1326. * ERROR TO *ABT* IF INCORRECT ARGUMENT.
  1327. *
  1328. * USES X - 0, 1, 2, 4, 6.
  1329. * A - 1, 4, 6.
  1330.  
  1331.  
  1332. SAP SUBR ENTRY/EXIT
  1333. SA1 FLST
  1334. SX2 =C* INCORRECT FILE STATUS.*
  1335. MX0 42
  1336. SA4 SAPA
  1337. SAP1 BX6 X0*X4 CHECK TABLE FOR MATCH
  1338. BX6 X1-X6
  1339. ZR X6,SAP2 IF SPECIFIED FILE STATUS FOUND
  1340. SA4 A4+B1
  1341. NZ X4,SAP1 IF NOT END OF TABLE
  1342. EQ ABT PROCESS INCORRECT FILE STATUS
  1343.  
  1344. SAP2 SX6 X4 SAVE FILE STATUS VALUE
  1345. SA6 A1
  1346. EQ SAPX RETURN
  1347.  
  1348.  
  1349. SAPA BSS 0 TABLE OF VALID FILE STATUSES
  1350. VFD 42/0LAD,18/0
  1351. VFD 42/0LNAD,18/NDST
  1352. CON 0
  1353. VAT SPACE 4,15
  1354. ** VAT - *OVWRITE* ARGUMENT PROCESSOR.
  1355. *
  1356. * PROCESSES THE OPTIONAL ARGUMENTS FOR THE *OVWRITE* COMMAND.
  1357. *
  1358. * ENTRY (OPARG) = *OP=* ARGUMENT.
  1359. *
  1360. * EXIT (OVWF) = 0, IF *Z* OPTION SELECTED.
  1361. * 3, IF *X* OPTION SELECTED.
  1362. * (B2) = COMMAND WORD ADDRESS.
  1363. *
  1364. * ERROR TO *ABT* IF INCORRECT ARGUMENT.
  1365. *
  1366. * USES X - 0, 2, 4, 6, 7.
  1367. * A - 4, 6.
  1368. * B - 2, 3, 5.
  1369.  
  1370. VAT SUBR ENTRY/EXIT
  1371. SX2 =C+ INCORRECT */* OPTION.+
  1372. SX6 3 PRESET *X* OPTION
  1373. MX0 -6
  1374. SA4 OPARG LIST OF OPTIONAL PARAMETERS
  1375. SB3 B1 INITIALIZE OPTION COUNTER
  1376. VAT1 LX4 6 RIGHT JUSTIFY CHARACTER
  1377. BX7 -X0*X4
  1378. ZR X7,VAT4 IF END OF OPTIONAL PARAMETERS
  1379. SB5 X7-1RZ
  1380. ZR B5,VAT3 IF *Z* PARAMETER
  1381. SB5 X7-1RX
  1382. ZR B5,VAT2 IF *X* PARAMETER
  1383. SB5 X7-1RR
  1384. NZ B5,ABT IF NOT A LEGAL OPTION
  1385. SB2 OVCR RESET COMMAND
  1386. EQ VAT1 CHECK NEXT OPTION
  1387.  
  1388. VAT2 SA6 OVWF SET *X* OPTION FLAG
  1389. VAT3 SB3 B3-1 DECREMENT OPTION COUNT
  1390. EQ VAT1 PROCESS NEXT OPTION
  1391.  
  1392. VAT4 LT B3,ABT IF INCORRECT OPTION COMBINATION
  1393. EQ VATX RETURN
  1394. POL SPACE 4,15
  1395. ** POL - PROCESS OPTION LIST.
  1396. *
  1397. * CRACKS THE COMMAND OPTIONAL ARGUMENTS
  1398. * AND EXECUTES THE ARGUMENT PROCESSOR DEFINED FOR
  1399. * THE COMMAND.
  1400. *
  1401. * ERROR TO *ABT* IF ARGUMENT ERROR.
  1402. *
  1403. * USES X - 1, 2, 4.
  1404. * A - 1, 4.
  1405. * B - 4, 5, 7.
  1406. *
  1407. * CALLS ARG, IRJ, RSR, SVR.
  1408. *
  1409. * NOTE THE ARGUMENT PROCESSOR SUBROUTINES MUST NOT
  1410. * DESTROY (B4), (A3), OR (X3).
  1411.  
  1412.  
  1413. POL SUBR ENTRY/EXIT
  1414. SA4 CSOC CHECK OPTION LIST PARAMETER COUNT
  1415. ZR X4,POLX IF NULL LIST, RETURN
  1416. SA1 B2+TACW GET ARGUMENT CONTROL WORD
  1417. ZR X1,POL1 IF NO ARGUMENTS ALLOWED
  1418.  
  1419. * PROCESS ARGUMENT LIST.
  1420.  
  1421. RJ SVR SAVE RESERVED REGISTERS
  1422. SB4 X4 SET ARGUMENT COUNT
  1423. SB5 X1 SET ARGUMENT TABLE ADDRESS
  1424. SA4 TOPS READ FIRST ARGUMENT
  1425. RJ ARG CRACK ARGUMENT LIST
  1426. RJ RSR RESTORE RESERVED REGISTERS
  1427. NZ X1,POL1 IF ERROR IN ARGUMENT LIST
  1428.  
  1429. * EXECUTE ARGUMENT PROCESSOR.
  1430.  
  1431. SA1 B2+TACW GET ARGUMENT CONTROL WORD
  1432. AX1 18
  1433. SB7 X1 SET PROCESSOR ADDRESS
  1434. ZR B7,POLX IF NO PROCESSOR DEFINED
  1435. RJ IRJ EXECUTE PROCESSOR
  1436. EQ POLX RETURN
  1437.  
  1438. * PROCESS ARGUMENT ERROR.
  1439.  
  1440. POL1 SX2 =C+ INCORRECT */* OPTION.+
  1441. EQ ABT ABORT
  1442. SPACE 4,10
  1443. * *CLEAR*, *OUT*, *OVWRITE*, *RETURN* AND *UNLOAD*
  1444. * COMMAND ARGUMENT TABLE.
  1445.  
  1446.  
  1447. TOARG BSS 0 ARGUMENT TABLE FOR *COMCARG*
  1448. OP ARG OPARG,OPARG
  1449. ARG
  1450. TSARG SPACE 4,10
  1451. * *SETFS* COMMAND ARGUMENT TABLE.
  1452.  
  1453.  
  1454. TSARG BSS 0
  1455. FS ARG FLST,FLST
  1456. ARG
  1457. MFILES SPACE 4,10
  1458. ** OVERLAID COMMON DECKS.
  1459.  
  1460.  
  1461. *CALL COMCARG
  1462. MFILES SPACE 4,10
  1463. ** TOPS - TABLE OF COMMAND */* OPTIONS.
  1464.  
  1465.  
  1466. TOPS BSS 0 OPTIONS TABLE FWA
  1467. TOPSE EQU TOPS+64 END OF TABLE
  1468.  
  1469.  
  1470. ERRNG RFL=-TOPSE PRESET OVERFLOWS BUFFERS.
  1471.  
  1472.  
  1473. END