

; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 1

;

;	0001	MODULE FIND (

;	0002			LANGUAGE (BLISS32),

;	0003			IDENT = 'A0015'

;	0004			) =

;	0005	BEGIN

;	0006	

;	0007	!

;	0008	! Copyright (c) 1977

;	0009	! Digital Equipment Corporation, Maynard, Massachusetts 01754

;	0010	!

;	0011	! This software is furnished  under a license for use only on a single

;	0012	! computer  system and  may be  copied only with  the inclusion of the

;	0013	! above copyright notice.  This software, or any other copies thereof,

;	0014	! may not be provided or  otherwise made available to any other person

;	0015	! except for use on such system and to one who agrees to these license

;	0016	! terms.  Title to and  ownership of the  software  shall at all times

;	0017	! remain in DEC.

;	0018	!

;	0019	! The information in this software is subject to change without notice

;	0020	! and should  not be construed  as a commitment  by Digital  Equipment

;	0021	! Corporation.

;	0022	!

;	0023	! DEC assumes  no  responsibility  for  the use or  reliability of its

;	0024	! software on equipment which is not supplied by DEC.

;	0025	

;	0026	!++

;	0027	!

;	0028	! FACILITY:  F11ACP Structure Level 1

;	0029	!

;	0030	! ABSTRACT:

;	0031	!

;	0032	!	This routine performs a find operation on the indicated directory.

;	0033	!

;	0034	! ENVIRONMENT:

;	0035	!

;	0036	!	STARLET operating system, including privileged system services

;	0037	!	and internal exec routines.

;	0038	!

;	0039	!--

;	0040	!

;	0041	!

;	0042	! AUTHOR:  Andrew C. Goldstein,	 CREATION DATE:  2-Jan-1977  22:11

;	0043	!

;	0044	! REVISION HISTORY:

;	0045	!

;	0046	!   Andrew C. Goldstein, 16-Feb-1977  14:59

;	0047	!   X0002 - Modify for condition handling

;	0048	!

;	0049	!   Andrew C. Goldstein, 25-Mar-1977  17:52

;	0050	!   X0003 - Remove FIB length check

;	0051	!

;	0052	!   Andrew C. Goldstein, 30-Mar-1977  17:22

;	0053	!   X0004 - Do FIB updates locally; simplify interface to RETURN_DIR

;	0054	!

;	0055	!   Andrew C. Goldstein, 1-Apr-1977  13:32



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 1-1

;

;	0056	!   X0005 - Add REMOVE subfunction

;	0057	!

;	0058	!   Andrew C. Goldstein, 14-Apr-1977  10:33

;	0059	!   X0006 - Save removed FID in secondary FIB

;	0060	!

;	0061	!   Andrew C. Goldstein, 19-May-1977  14:31

;	0062	!   X0007 - Add wild card name, default version logic

;	0063	!

;	0064	!   Andrew C. Goldstein, 26-Aug-1977  10:42

;	0065	!   X0008 - Add performance metering

;	0066	!

;	0067	!   Andrew C. Goldstein, 26-Sep-1977  15:04

;	0068	!   X0009 - Add SS$_NOMOREFILES status

;	0069	!

;	0070	!   Andrew C. Goldstein, 13-Oct-1977  11:41

;	0071	!   X0010 - Put file ID in name block for find/remove by FID

;	0072	!

;	0073	!   Andrew C. Goldstein, 1-Feb-1978  16:02

;	0074	!   X0011 - Return zero context on search failure

;	0075	!

;	0076	!   Andrew C. Goldstein, 17-Feb-1978  14:11

;	0077	!   X0012 - Use new bug check

;	0078	!

;	0079	!   Andrew C. Goldstein, 6-Jun-78  15:58

;	0080	!   A0013 - Add implicit spooling support

;	0081	!

;	0082	!   Andrew C. Goldstein, 21-Jun-78  18:02

;	0083	!   A0014 - Add RMS directory modification interlock

;	0084	!

;	0085	!   Andrew C. Goldstein, 6-Jul-78  16:15

;	0086	!   A0015 - Use separate storage for removed file ID

;	0087	!

;	0088	!**

;	0089	

;	0090	

;	0091	LIBRARY 'SYS$LIBRARY:LIB.L32';

;	0092	REQUIRE 'SRC$:FCPDEF.B32';

;	0411	

;	0412	

;	0413	FORWARD ROUTINE

;	0414		FIND		: NOVALUE,	! find directory entry

;	0415		UPDATE_DIRSEQ;			! bump UCB directory sequence count



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2

;

;	0416	GLOBAL ROUTINE FIND (ABD, FIB, REMOVE) : NOVALUE =

;	0417	

;	0418	!++

;	0419	!

;	0420	! FUNCTIONAL DESCRIPTION:

;	0421	!

;	0422	!	This routine performs a FIND operation on the indicated directory.

;	0423	!

;	0424	! CALLING SEQUENCE:

;	0425	!	FIND (ARG1, ARG2, ARG3)

;	0426	!

;	0427	! INPUT PARAMETERS:

;	0428	!	ARG1: address of descriptor list in buffer packet

;	0429	!	ARG2: address of FIB

;	0430	!	ARG3: 0 to just do a find

;	0431	!	      1 to remove the found entry

;	0432	!

;	0433	! IMPLICIT INPUTS:

;	0434	!	NONE

;	0435	!

;	0436	! OUTPUT PARAMETERS:

;	0437	!	ARG2: file ID and context returned in FIB

;	0438	!

;	0439	! IMPLICIT OUTPUTS:

;	0440	!	DIR_RECORD: record number of found directory entry

;	0441	!

;	0442	! ROUTINE VALUE:

;	0443	!	NONE

;	0444	!

;	0445	! SIDE EFFECTS:

;	0446	!	Directory LRU may be altered

;	0447	!	directory blocks read

;	0448	!

;	0449	!--

;	0450	

;	0451	BEGIN

;	0452	

;	0453	MAP

;	0454		ABD		: REF BBLOCKVECTOR [,ABD$C_LENGTH],

;	0455						! descriptor list arg

;	0456		FIB		: REF BBLOCK;	! FIB argument

;	0457	

;	0458	LOCAL

;	0459		NAMEBLOCK	: BBLOCK [NMB$C_LENGTH],

;	0460						! RAD-50 name block

;	0461		COMPLEX,			! complex operation flag

;	0462		SAVED_FLAGS,			! original flag bits for operation

;	0463		SAVED_CONTEXT,			! record number of first occurrence

;	0464		STRING		: VECTOR [20, BYTE],

;	0465						! space for result string

;	0466		COUNT,				! count of name string

;	0467		STRINGP,			! address of name string

;	0468		RECADDR		: REF BBLOCK;	! pointer to found directory entry

;	0469	

;	0470	EXTERNAL



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-1

;

;	0471		CLEANUP_FLAGS	: BITVECTOR,	! cleanup action flags

;	0472		DIR_RECORD,			! record number of directory entry

;	0473		SUPER_FID	: BBLOCK;	! file ID of superseded/deleted file

;	0474	

;	0475	EXTERNAL ROUTINE

;	0476		PMS_START_SUB,			! start subfunction metering

;	0477		PMS_END_SUB,			! end subfunction metering

;	0478		COPY_NAME,			! copy file name to result string

;	0479		DIR_ACCESS,			! access the directory

;	0480		MAKE_NAMEBLOCK,			! construct name block

;	0481		DIR_SCAN,			! search the directory

;	0482		MAKE_STRING,			! convert directory entry to string

;	0483		RETURN_DIR,			! return data to buffer packet

;	0484		DIRPUT;				! write directory record

;	0485	

;	0486	

;	0487	! Start metering for this subfunction.

;	0488	!

;	0489	

;	0490	PMS_START_SUB (PMS_FIND);

;	0491	

;	0492	! If this is an operation on a spooled device, noop it and return a file ID

;	0493	! of -2, -2 with success.

;	0494	!

;	0495	

;	0496	IF .CLEANUP_FLAGS[CLF_SPOOLFILE]

;	0497	THEN

;	0498	    BEGIN

;	0499	    FIB[FIB$W_FID_NUM] = -2;

;	0500	    FIB[FIB$W_FID_SEQ] = -2;

;	0501	    FIB[FIB$W_FID_RVN] = 0;

;	0502	    KERNEL_CALL (COPY_NAME, .ABD);

;	0503	    RETURN;

;	0504	    END;

;	0505	

;	0506	! Find the name string in the buffer packet. Construct the RAD-50 name block

;	0507	! from it and the other data in the FIB.

;	0508	!

;	0509	

;	0510	COUNT = .ABD[ABD$C_NAME, ABD$W_COUNT];

;	0511	STRINGP = .ABD[ABD$C_NAME, ABD$W_TEXT] + ABD[ABD$C_NAME, ABD$W_TEXT] + 1;

;	0512	

;	0513	MAKE_NAMEBLOCK (.COUNT, .STRINGP, NAMEBLOCK);

;	0514	CH$MOVE (FIB$S_FID, FIB[FIB$W_FID], NAMEBLOCK[NMB$W_FID]);

;	0515	NAMEBLOCK[NMB$W_FLAGS] = .FIB[FIB$W_NMCTL];

;	0516	NAMEBLOCK[NMB$W_CONTEXT] = .FIB[FIB$L_WCC];

;	0517	

;	0518	! Determine if this is a complex operation (wild card name, default version).

;	0519	! If so, set up the required parameters.

;	0520	!

;	0521	

;	0522	COMPLEX = 0;

;	0523	IF (.NAMEBLOCK[NMB$V_ALLNAM] OR .NAMEBLOCK[NMB$V_ALLTYP])

;	0524	AND NOT .NAMEBLOCK[NMB$V_ALLVER]

;	0525	AND .NAMEBLOCK[NMB$W_VERSION] EQL 0



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-2

;

;	0526	THEN

;	0527	    BEGIN

;	0528	    COMPLEX = 1;

;	0529	    NAMEBLOCK[NMB$V_ALLVER] = 1;

;	0530	    SAVED_FLAGS = .NAMEBLOCK[NMB$W_FLAGS];

;	0531	    END;

;	0532	

;	0533	! Access the directory. We need write access if this is a REMOVE.

;	0534	!

;	0535	

;	0536	DIR_ACCESS (.FIB, .REMOVE);

;	0537	

;	0538	! Now search the directory. If this is a complex operation, we may

;	0539	! loop several times before finding a suitable entry.

;	0540	!

;	0541	

;	0542	WHILE 1 DO

;	0543	    BEGIN

;	0544	    RECADDR = DIR_SCAN (NAMEBLOCK, 0);

;	0545	    IF .RECADDR EQL 0			! if not found

;	0546	    THEN

;	0547		IF .FIB[FIB$L_WCC] EQL 0

;	0548		THEN ERR_EXIT (SS$_NOSUCHFILE)

;	0549		ELSE

;	0550		    BEGIN

;	0551		    FIB[FIB$L_WCC] = 0;

;	0552		    ERR_EXIT (SS$_NOMOREFILES);

;	0553		    END;

;	0554	    SAVED_CONTEXT = .DIR_RECORD;	! save record number found

;	0555	    IF NOT .COMPLEX THEN EXITLOOP;	! for simple lookups that's all

;	0556	

;	0557	! This is a complex operation. We have now found some occurrence of the desired

;	0558	! file. Now search from the beginning of the directory for the first occurring

;	0559	! version of this entry. If it precedes the one found, then we have already

;	0560	! found it on a previous call, so try from the start for something new. If

;	0561	! it follows the one found, we are in trouble.

;	0562	!

;	0563	

;	0564	    CH$MOVE (NMB$C_DIRENTRY-2, .RECADDR, NAMEBLOCK);

;	0565	    NAMEBLOCK[NMB$W_FLAGS] = NMB$M_ALLVER;

;	0566	    NAMEBLOCK[NMB$W_CONTEXT] = 0;

;	0567	

;	0568	    RECADDR = DIR_SCAN (NAMEBLOCK, 0);

;	0569	    IF .RECADDR EQL 0 OR .DIR_RECORD GTRU .SAVED_CONTEXT

;	0570	    THEN BUG_CHECK (DIRENTRY, FATAL, 'ACP failed to find same directory entry');

;	0571	

;	0572	! If the entry found on the second scan is the same as the first, then this is

;	0573	! a first occurrence. Now scan the remainder of the directory for the latest

;	0574	! version of this occurrence. We will return the latest version entry to

;	0575	! the caller, but the context of the first occurrence found.

;	0576	!

;	0577	

;	0578	    IF .DIR_RECORD EQL .SAVED_CONTEXT

;	0579	    THEN

;	0580		BEGIN



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-3

;

;	0581		NAMEBLOCK[NMB$W_FLAGS] = 0;

;	0582		NAMEBLOCK[NMB$W_CONTEXT] = .SAVED_CONTEXT - 1;

;	0583		RECADDR = DIR_SCAN (NAMEBLOCK, 0);

;	0584		IF .RECADDR EQL 0

;	0585		THEN BUG_CHECK (DIRENTRY, FATAL, 'ACP failed to find same directory entry');

;	0586		EXITLOOP;

;	0587		END;

;	0588	

;	0589	! This was a duplicate. Restore the original flags and continue the basic

;	0590	! scan from where we left off.

;	0591	!

;	0592	

;	0593	    NAMEBLOCK[NMB$W_FLAGS] = .SAVED_FLAGS;

;	0594	    NAMEBLOCK[NMB$W_CONTEXT] = .SAVED_CONTEXT;

;	0595	    END;				! end of directory scan loop

;	0596	

;	0597	! Now convert the resulting directory entry into the ASCII resultant string.

;	0598	! Return this and the record number to the buffer packet.

;	0599	!

;	0600	

;	0601	CH$MOVE (FIB$S_FID, RECADDR[NMB$W_FID], FIB[FIB$W_FID]);

;	0602	FIB[FIB$L_WCC] =

;	0603	    (

;	0604	    IF .FIB[FIB$V_WILD]

;	0605	    THEN .SAVED_CONTEXT

;	0606	    ELSE 0

;	0607	    );

;	0608	COUNT = MAKE_STRING (.RECADDR, STRING);

;	0609	KERNEL_CALL (RETURN_DIR, .COUNT, STRING, .ABD);

;	0610	

;	0611	! If a remove operation is requested, do so by simply zeroing the file number

;	0612	! word of the directory entry and writing it back. Note that we save the

;	0613	! removed FID for replacement in case of subsequent error.

;	0614	! If the entry being removed is of the form xxx.DIR;1, bump the sequence count

;	0615	! in the UCB to invalidate RMS caches.

;	0616	!

;	0617	

;	0618	IF .REMOVE

;	0619	THEN

;	0620	    BEGIN

;	0621	    CH$MOVE (FIB$S_FID, RECADDR[NMB$W_FID],SUPER_FID);

;	0622	    RECADDR[NMB$W_FID_NUM] = 0;

;	0623	    DIRPUT (.RECADDR);

;	0624	    CLEANUP_FLAGS[CLF_REENTER] = 1;

;	0625	

;	0626	    IF  .RECADDR[NMB$W_TYPE] EQL %RAD50_11 'DIR'

;	0627	    AND .RECADDR[NMB$W_VERSION] EQL 1

;	0628	    THEN KERNEL_CALL (UPDATE_DIRSEQ);

;	0629	    END;

;	0630	

;	0631	! Stop metering of this subfunction

;	0632	!

;	0633	

;	0634	PMS_END_SUB ();

;	0635	



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-4

;

;	0636	END;					! end of routine FIND





							    .TITLE  FIND

							    .IDENT  \A0015\



							    .PSECT  $LOCKEDC2$,NOWRT,2



				  FEFF  0000  00000 P.AAA:  .WORD   0, -257						      ;

					0000* 00004 	    .WORD   <BUG$_DIRENTRY!4>					      ;

					      00006	    .BLKB   2

				  FEFF  0000  00008 P.AAB:  .WORD   0, -257						      ;

					0000* 0000C 	    .WORD   <BUG$_DIRENTRY!4>					      ;

					      0000E	    .BLKB   2



							    .EXTRN  CLEANUP_FLAGS, DIR_RECORD, SUPER_FID, PMS_START_SUB

							    .EXTRN  PMS_END_SUB, COPY_NAME, DIR_ACCESS, MAKE_NAMEBLOCK

							    .EXTRN  DIR_SCAN, MAKE_STRING, RETURN_DIR, DIRPUT, SYS$CMKRNL

							    .EXTRN  BUG$_DIRENTRY



							    .PSECT  $CODE$,NOWRT,2



					 0FFC 00000 	    .ENTRY  FIND, Save R2,R3,R4,R5,R6,R7,R8,R9,R10,R11		      ; 0416

		         5B 00000000G  9F  9E 00002 	    MOVAB   @#SYS$CMKRNL, R11					      ;

		         5E 	       28  C2 00009 	    SUBL2   #40, SP						      ;

				       06  DD 0000C 	    PUSHL   #6							      ; 0490

		  0000G  CF	       01  FB 0000E 	    CALLS   #1, PMS_START_SUB					      ;

	   1E 	  0000G  CF	       07  E1 00013 	    BBC     #7, CLEANUP_FLAGS, 1$				      ; 0496

		         50 	  08   AC  D0 00019 	    MOVL    FIB, R0						      ; 0499

		    04   A0 FFFEFFFE   8F  D0 0001D 	    MOVL    #-65538, 4(R0)					      ;

				  08   A0  B4 00025 	    CLRW    8(R0)						      ; 0501

				  04   AC  DD 00028 	    PUSHL   ABD							      ; 0502

				       01  DD 0002B 	    PUSHL   #1							      ;

				       5E  DD 0002D 	    PUSHL   SP							      ;

				0000G  CF  9F 0002F 	    PUSHAB  COPY_NAME						      ;

		         6B 	       04  FB 00033 	    CALLS   #4, SYS$CMKRNL					      ;

					   04 00036 	    RET     							      ; 0503

		         50 	  04   AC  D0 00037 1$:     MOVL    ABD, R0						      ; 0510

		         5A 	  12   A0  3C 0003B 	    MOVZWL  18(R0), COUNT					      ;

		         51 	  10   A0  9E 0003F 	    MOVAB   16(R0), R1						      ; 0511

		         50 	       61  3C 00043 	    MOVZWL  (R1), R0						      ;

		         50 	  01 A140  9E 00046 	    MOVAB   1(R1)[R0], STRINGP					      ;

				  14   AE  9F 0004B 	    PUSHAB  NAMEBLOCK						      ; 0513

				       50  DD 0004E 	    PUSHL   STRINGP						      ;

				       5A  DD 00050 	    PUSHL   COUNT						      ;

		  0000G  CF	       03  FB 00052 	    CALLS   #3, MAKE_NAMEBLOCK					      ;

		         57 	  08   AC  D0 00057 	    MOVL    FIB, R7						      ; 0514

      14   AE	    04   A7	       06  28 0005B 	    MOVC3   #6, 4(R7), NAMEBLOCK				      ;

		    24   AE	  14   A7  B0 00061 	    MOVW    20(R7), NAMEBLOCK+16				      ; 0515

		    26   AE	  10   A7  B0 00066 	    MOVW    16(R7), NAMEBLOCK+18				      ; 0516

				       56  D4 0006B 	    CLRL    COMPLEX						      ; 0522

	   05 	    24   AE	       05  E0 0006D 	    BBS     #5, NAMEBLOCK+16, 2$				      ; 0523

	   15 	    24   AE	       04  E1 00072 	    BBC     #4, NAMEBLOCK+16, 3$				      ;

	   10 	    24   AE	       03  E0 00077 2$:     BBS     #3, NAMEBLOCK+16, 3$				      ; 0524

				  22   AE  B5 0007C 	    TSTW    NAMEBLOCK+14					      ; 0525



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-5

;

				       0B  12 0007F 	    BNEQ    3$							      ;

		         56 	       01  D0 00081 	    MOVL    #1, COMPLEX						      ; 0528

		    24   AE	       08  88 00084 	    BISB2   #8, NAMEBLOCK+16					      ; 0529

		         59 	  24   AE  3C 00088 	    MOVZWL  NAMEBLOCK+16, SAVED_FLAGS				      ; 0530

				  0C   AC  DD 0008C 3$:     PUSHL   REMOVE						      ; 0536

				       57  DD 0008F 	    PUSHL   R7							      ;

		  0000G  CF	       02  FB 00091 	    CALLS   #2, DIR_ACCESS					      ;

				       7E  D4 00096 4$:     CLRL    -(SP)						      ; 0544

				  18   AE  9F 00098 	    PUSHAB  NAMEBLOCK						      ;

		  0000G  CF	       02  FB 0009B 	    CALLS   #2, DIR_SCAN					      ;

		         57 	       50  D0 000A0 	    MOVL    R0, RECADDR						      ;

				       16  12 000A3 	    BNEQ    6$							      ; 0545

		         50 	  08   AC  D0 000A5 	    MOVL    FIB, R0						      ; 0547

				  10   A0  D5 000A9 	    TSTL    16(R0)						      ;

				       06  12 000AC 	    BNEQ    5$							      ;

				0910   8F  BF 000AE 	    CHMU    #2320						      ; 0548

				       07  11 000B2 	    BRB     6$							      ; 0547

				  10   A0  D4 000B4 5$:     CLRL    16(R0)						      ; 0551

				0930   8F  BF 000B7 	    CHMU    #2352						      ; 0552

		         58 	0000G  CF  D0 000BB 6$:     MOVL    DIR_RECORD, SAVED_CONTEXT				      ; 0554

		         53 	       56  E9 000C0 	    BLBC    COMPLEX, 10$					      ; 0555

      14   AE	         67 	       0E  28 000C3 	    MOVC3   #14, (RECADDR), NAMEBLOCK				      ; 0564

		    24   AE	       08  D0 000C8 	    MOVL    #8, NAMEBLOCK+16					      ; 0565

				       7E  D4 000CC 	    CLRL    -(SP)						      ; 0568

				  18   AE  9F 000CE 	    PUSHAB  NAMEBLOCK						      ;

		  0000G  CF	       02  FB 000D1 	    CALLS   #2, DIR_SCAN					      ;

		         57 	       50  D0 000D6 	    MOVL    R0, RECADDR						      ;

				       07  13 000D9 	    BEQL    7$							      ; 0569

		         58 	0000G  CF  D1 000DB 	    CMPL    DIR_RECORD, SAVED_CONTEXT				      ;

				       05  1B 000E0 	    BLEQU   8$							      ;

		  0000'  CF	       00  FB 000E2 7$:     CALLS   #0, P.AAA						      ; 0570

		         58 	0000G  CF  D1 000E7 8$:     CMPL    DIR_RECORD, SAVED_CONTEXT				      ; 0578

				       1E  12 000EC 	    BNEQ    9$							      ;

				  24   AE  B4 000EE 	    CLRW    NAMEBLOCK+16					      ; 0581

      26   AE	         58 	       01  A3 000F1 	    SUBW3   #1, SAVED_CONTEXT, NAMEBLOCK+18			      ; 0582

				       7E  D4 000F6 	    CLRL    -(SP)						      ; 0583

				  18   AE  9F 000F8 	    PUSHAB  NAMEBLOCK						      ;

		  0000G  CF	       02  FB 000FB 	    CALLS   #2, DIR_SCAN					      ;

		         57 	       50  D0 00100 	    MOVL    R0, RECADDR						      ;

				       11  12 00103 	    BNEQ    10$							      ; 0584

		  0000'  CF	       00  FB 00105 	    CALLS   #0, P.AAB						      ; 0585

				       0A  11 0010A 	    BRB     10$							      ; 0586

		    24   AE	       59  B0 0010C 9$:     MOVW    SAVED_FLAGS, NAMEBLOCK+16				      ; 0593

		    26   AE	       58  B0 00110 	    MOVW    SAVED_CONTEXT, NAMEBLOCK+18				      ; 0594

				       80  11 00114 	    BRB     4$							      ; 0542

		         59 	  08   AC  D0 00116 10$:    MOVL    FIB, R9						      ; 0601

      04   A9	         67 	       06  28 0011A 	    MOVC3   #6, (RECADDR), 4(R9)				      ;

		         05 	  15   A9  E9 0011F 	    BLBC    21(R9), 11$						      ; 0604

		         50 	       58  D0 00123 	    MOVL    SAVED_CONTEXT, R0					      ; 0603

				       02  11 00126 	    BRB     12$							      ;

				       50  D4 00128 11$:    CLRL    R0							      ;

		    10   A9	       50  D0 0012A 12$:    MOVL    R0, 16(R9)						      ; 0602

				4080   8F  BB 0012E 	    PUSHR   #^M<R7,SP>						      ; 0608

		  0000G  CF	       02  FB 00132 	    CALLS   #2, MAKE_STRING					      ;

		         5A 	       50  D0 00137 	    MOVL    R0, COUNT						      ;



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 2-6

;

				  04   AC  DD 0013A 	    PUSHL   ABD							      ; 0609

				  04   AE  9F 0013D 	    PUSHAB  STRING						      ;

				       5A  DD 00140 	    PUSHL   COUNT						      ;

				       03  DD 00142 	    PUSHL   #3							      ;

				       5E  DD 00144 	    PUSHL   SP							      ;

				0000G  CF  9F 00146 	    PUSHAB  RETURN_DIR						      ;

		         6B 	       06  FB 0014A 	    CALLS   #6, SYS$CMKRNL					      ;

		         2E 	  0C   AC  E9 0014D 	    BLBC    REMOVE, 13$						      ; 0618

    0000G  CF	         67 	       06  28 00151 	    MOVC3   #6, (RECADDR), SUPER_FID				      ; 0621

				       67  B4 00157 	    CLRW    (RECADDR)						      ; 0622

				       57  DD 00159 	    PUSHL   RECADDR						      ; 0623

		  0000G  CF	       01  FB 0015B 	    CALLS   #1, DIRPUT						      ;

		  0000G  CF	  80   8F  88 00160 	    BISB2   #128, CLEANUP_FLAGS+2				      ; 0624

		  1A7A   8F	  0C   A7  B1 00166 	    CMPW    12(RECADDR), #6778					      ; 0626

				       11  12 0016C 	    BNEQ    13$							      ;

		         01 	  0E   A7  B1 0016E 	    CMPW    14(RECADDR), #1					      ; 0627

				       0B  12 00172 	    BNEQ    13$							      ;

				       7E  D4 00174 	    CLRL    -(SP)						      ; 0628

				       5E  DD 00176 	    PUSHL   SP							      ;

				0000V  CF  9F 00178 	    PUSHAB  UPDATE_DIRSEQ					      ;

		         6B 	       03  FB 0017C 	    CALLS   #3, SYS$CMKRNL					      ;

		  0000G  CF	       00  FB 0017F 13$:    CALLS   #0, PMS_END_SUB					      ; 0634

					   04 00184 	    RET     							      ; 0416



; Routine Size:  389 bytes







; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 3

;

;	0637	ROUTINE UPDATE_DIRSEQ =

;	0638	

;	0639	!++

;	0640	!

;	0641	! FUNCTIONAL DESCRIPTION:

;	0642	!

;	0643	!	This routine bumps the directory sequence count in the UCB to invalidate

;	0644	!	RMS directory caches on the volume.

;	0645	!

;	0646	!

;	0647	! CALLING SEQUENCE:

;	0648	!	UPDATE_DIRSEQ ()

;	0649	!

;	0650	! INPUT PARAMETERS:

;	0651	!	NONE

;	0652	!

;	0653	! IMPLICIT INPUTS:

;	0654	!	CURRENT_UCB: UCB of device in use

;	0655	!

;	0656	! OUTPUT PARAMETERS:

;	0657	!	NONE

;	0658	!

;	0659	! IMPLICIT OUTPUTS:

;	0660	!	directory sequence count incremented

;	0661	!

;	0662	! ROUTINE VALUE:

;	0663	!	1

;	0664	!

;	0665	! SIDE EFFECTS:

;	0666	!	NONE

;	0667	!

;	0668	!--

;	0669	

;	0670	BEGIN

;	0671	

;	0672	EXTERNAL

;	0673		CURRENT_UCB	: REF BBLOCK;	! UCB of device

;	0674	

;	0675	

;	0676	CURRENT_UCB[UCB$W_DIRSEQ] = .CURRENT_UCB[UCB$W_DIRSEQ] + 1;

;	0677	

;	0678	RETURN 1;

;	0679	

;	0680	END;					! end of routine UPDATE_DIRSEQ







							    .EXTRN  CURRENT_UCB



					 0000 00185 UPDATE_DIRSEQ:

							    .WORD   Save nothing					      ; 0637

		         50 	0000G  CF  D0 00187 	    MOVL    CURRENT_UCB, R0					      ; 0676

				0088   C0  B6 0018C 	    INCW    136(R0)						      ;

		         50 	       01  D0 00190 	    MOVL    #1, R0						      ; 0678

					   04 00193 	    RET     							      ; 0637



; Bliss-32 10.1-416	Monday 21-AUG-1978 22:57:29	DBB3:[F11A.SRC]FIND.B32;13					Page 3-1

;



; Routine Size:  15 bytes





;	0681	

;	0682	END

;	0683	ELUDOM













;				       PSECT SUMMARY

;

;	Name		 Bytes			       Attributes

;

;  $LOCKEDC2$     	    16  NOWRT,  RD ,  EXE,NOSHR,  LCL,  REL,  CON,NOPIC,ALIGN(2)

;  $CODE$         	   404  NOWRT,  RD ,  EXE,NOSHR,  LCL,  REL,  CON,NOPIC,ALIGN(2)









;				LIBRARY STATISTICS

;

;					     -------- Symbols --------    Blocks

;	File				     Total    Loaded   Percent      Read

;

;  DBA4:[SYSLIB]LIB.L32;1		      5582        28         0       237











; Size:		404 code + 16 data bytes

; Run Time:	00:10.3

; Elapsed Time:	00:22.6

; Memory Used:	342 pages

; Compilation Complete

