

; Bliss-32 7.352	Saturday 22-AUG-1978 00:14:15	DBB3:[MOUNT.SRC]TRNLOG.B32;8					Page 1

; Digital Equipment Corporation

;

;	0001	MODULE TRNLOG (

;	0002			LANGUAGE (BLISS32),

;	0003			IDENT = 'X0002'

;	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:  MOUNT Utility Structure Levels 1 & 2

;	0029	!

;	0030	! ABSTRACT:

;	0031	!

;	0032	!	This routine performs simple recursive logical name translation.

;	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:  9-Oct-1977  16:10

;	0043	!

;	0044	! REVISION HISTORY:

;	0045	!

;	0046	!   Andrew C. Goldstein, 2-Feb-1978  11:28

;	0047	!   X0002 - Stop translation when '_' is seen

;	0048	!

;	0049	!**

;	0050	

;	0051	

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

;	0053	REQUIRE 'SRC$:MOUDEF.B32';

;	0360	REQUIRE 'LIBD$:[VMSLIB.OBJ]MOUNTMSG.B32';



; Bliss-32 7.352	Saturday 22-AUG-1978 00:14:15	DBB3:[MOUNT.SRC]TRNLOG.B32;8					Page 2

; Digital Equipment Corporation

;

;	0460	GLOBAL ROUTINE TRAN_LOGNAME (LOG_NAME, RESULT) : NOVALUE =

;	0461	

;	0462	!++

;	0463	!

;	0464	! FUNCTIONAL DESCRIPTION:

;	0465	!

;	0466	!	This routine performs simple recursive logical name translation.

;	0467	!

;	0468	!

;	0469	! CALLING SEQUENCE:

;	0470	!	TRAN_LOGNAME (ARG1, ARG2)

;	0471	!

;	0472	! INPUT PARAMETERS:

;	0473	!	ARG1: descriptor of logical name to translate

;	0474	!

;	0475	! IMPLICIT INPUTS:

;	0476	!	NONE

;	0477	!

;	0478	! OUTPUT PARAMETERS:

;	0479	!	ARG2: descriptor of result string buffer

;	0480	!		(first word receives length of result)

;	0481	!

;	0482	! IMPLICIT OUTPUTS:

;	0483	!	NONE

;	0484	!

;	0485	! ROUTINE VALUE:

;	0486	!	NONE

;	0487	!

;	0488	! SIDE EFFECTS:

;	0489	!	NONE

;	0490	!

;	0491	!--

;	0492	

;	0493	BEGIN

;	0494	

;	0495	MAP

;	0496		LOG_NAME	: REF VECTOR,	! logical name descriptor

;	0497		RESULT		: REF VECTOR;	! result string descriptor

;	0498	

;	0499	LOCAL

;	0500		NAME_DESC	: VECTOR [2],	! descriptor of current logical name string

;	0501		STATUS,				! system service status

;	0502		P;				! string search pointer

;	0503	

;	0504	! We iterate on logical name translation until the service returns SS$_NOTRAN.

;	0505	! Perform device name extraction by using only the part of the logical name to

;	0506	! the left of the colon (if any), also checking for node names.

;	0507	!

;	0508	

;	0509	NAME_DESC[0] = .LOG_NAME[0];		! get initial logical name

;	0510	NAME_DESC[1] = .RESULT[1];

;	0511	CH$COPY (.LOG_NAME[0], .LOG_NAME[1], 0, .RESULT[0], .RESULT[1]);

;	0512	

;	0513	IF BEGIN

;	0514	DECR N FROM 10 TO 1 DO



; Bliss-32 7.352	Saturday 22-AUG-1978 00:14:15	DBB3:[MOUNT.SRC]TRNLOG.B32;8					Page 2-1

; Digital Equipment Corporation

;

;	0515	    BEGIN

;	0516	    P = CH$FIND_CH (.NAME_DESC[0], .NAME_DESC[1], ':');

;	0517	    IF NOT CH$FAIL (.P)

;	0518	    THEN

;	0519		BEGIN

;	0520		IF .(.P)<0,16> EQL '::'

;	0521		THEN ERR_EXIT (MOUN$_NONLOCAL);

;	0522		NAME_DESC[0] = .P - .NAME_DESC[1];

;	0523		END;

;	0524	

;	0525	    IF CH$RCHAR (.NAME_DESC[1]) EQL '_'

;	0526	    THEN EXITLOOP 0;

;	0527	

;	0528	    STATUS = $TRNLOG (LOGNAM = NAME_DESC[0],

;     P 0529			      RSLLEN = NAME_DESC[0],

;     P 0530			      RSLBUF = RESULT[0]);

;	0531	    IF .STATUS EQL SS$_NOTRAN THEN EXITLOOP 0;

;	0532	    IF NOT .STATUS THEN ERR_EXIT (.STATUS);

;	0533	    END

;	0534	END

;	0535	THEN ERR_EXIT (MOUN$_NOTRAN);

;	0536	

;	0537	RESULT[0] = .NAME_DESC[0];

;	0538	

;	0539	END;					! end of routine TRAN_LOGNAME





							    .TITLE  TRNLOG

							    .IDENT  \X0002\



							    .GLOBL  SYS$TRNLOG



							    .PSECT  $CODE$,NOWRT,2



					 087C 00000 	    .ENTRY  TRAN_LOGNAME, Save R2,R3,R4,R5,R6,R11		      ; 0460

		         5B 00000000G  00  9E 00002 	    MOVAB   LIB$STOP, R11					      ;

		         5E	       04  C2 00009 	    SUBL2   #4, SP						      ;

		         50	  04   AC  D0 0000C 	    MOVL    LOG_NAME, R0					      ; 0509

				       60  DD 00010 	    PUSHL   (R0)						      ;

		         56	  08   AC  D0 00012 	    MOVL    RESULT, R6						      ; 0510

		    04   AE	  04   A6  D0 00016 	    MOVL    4(R6), NAME_DESC+4					      ;

	   00	    04   B0	       60  2C 0001B 	    MOVC5   (R0), @4(R0), #0, (R6), @4(R6)			      ; 0511

		    04   B6	       66     00020									      ;

		         54	       0A  D0 00023 	    MOVL    #10, N						      ; 0514

      04   BE	         6E	       3A  3A 00026 1$:     LOCC    #58, NAME_DESC, @NAME_DESC+4			      ; 0516

				       02  12 0002B 	    BNEQ    2$							      ;

				       51  D4 0002D 	    CLRL    R1							      ;

		         52	       51  D0 0002F 2$:     MOVL    R1, P						      ;

				       15  13 00032 	    BEQL    4$							      ; 0517

		  3A3A   8F	       62  B1 00034 	    CMPW    (P), #14906						      ; 0520

				       09  12 00039 	    BNEQ    3$							      ;

			    0072803C   8F  DD 0003B 	    PUSHL   #7503932						      ; 0521

		         6B	       01  FB 00041 	    CALLS   #1, LIB$STOP					      ;

	   6E	         52	  04   AE  C3 00044 3$:     SUBL3   NAME_DESC+4, P, NAME_DESC				      ; 0522

		    5F   8F	  04   BE  91 00049 4$:     CMPB    @NAME_DESC+4, #95					      ; 0525



; Bliss-32 7.352	Saturday 22-AUG-1978 00:14:15	DBB3:[MOUNT.SRC]TRNLOG.B32;8					Page 2-2

; Digital Equipment Corporation

;

				       33  13 0004E 	    BEQL    6$							      ;

				       7E  7C 00050 	    CLRQ    -(SP)						      ; 0530

				       7E  D4 00052 	    CLRL    -(SP)						      ;

				       56  DD 00054 	    PUSHL   R6							      ;

				  10   AE  9F 00056 	    PUSHAB  NAME_DESC						      ;

				  14   AE  9F 00059 	    PUSHAB  NAME_DESC						      ;

	      00000000G  9F	       06  FB 0005C 	    CALLS   #6, @#SYS$TRNLOG					      ;

		         53	       50  D0 00063 	    MOVL    R0, STATUS						      ;

	      00000629   8F	       53  D1 00066 	    CMPL    STATUS, #1577					      ; 0531

				       14  13 0006D 	    BEQL    6$							      ;

		         05	       53  E8 0006F 	    BLBS    STATUS, 5$						      ; 0532

				       53  DD 00072 	    PUSHL   STATUS						      ;

		         6B	       01  FB 00074 	    CALLS   #1, LIB$STOP					      ;

		         AC	       54  F5 00077 5$:     SOBGTR  N, 1$						      ; 0514

			    00728044   8F  DD 0007A 	    PUSHL   #7503940						      ; 0535

		         6B	       01  FB 00080 	    CALLS   #1, LIB$STOP					      ;

		         66	       6E  D0 00083 6$:     MOVL    NAME_DESC, (R6)					      ; 0537

					   04 00086 	    RET     							      ; 0460



; Routine Size:  135 bytes





;	0540	

;	0541	END

;	0542	ELUDOM









							    .GLOBL  LIB$STOP



;				       PSECT SUMMARY

;

;	Name		 Bytes			       Attributes

;

;  $CODE$         	   135  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         6         0       226











; Size:		135 code + 0 data bytes

; Run Time:	00:13.2

; Elapsed Time:	00:35.5

; Memory Used:	283 pages



; Bliss-32 7.352	Saturday 22-AUG-1978 00:14:15									Page 2-3

; Digital Equipment Corporation

;

; Compilation Complete

