MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   0

TABLE OF CONTENTS   



   (1)      72  ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE

   (1)     170  DEALLOCATE SYMBOL TABLE ENTRY

   (1)     201  SEARCH FOR SYMBOL ENTRY

   (1)     244  SEARCH SPECIFIC SYMBOL TABLE FOR ENTRY

   (1)     287  SEARCH FOR SPECIAL SYMBOL

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   1

01                                                                                                                               (1)



                                     0000     1 	.TITLE	MCRSYMBOL - SYMBOL TABLE MANIPULATION ROUTINES

                                     0000     2 	.IDENT	/01/

                                     0000     3  

                                     0000     4 ;

                                     0000     5 ; COPYRIGHT (C) 1977

                                     0000     6 ; DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.

                                     0000     7 ;

                                     0000     8 ; THIS SOFTWARE IS FURNISHED UNDER  A LICENSE FOR USE ONLY  ON  A

                                     0000     9 ; SINGLE COMPUTER SYSTEM AND MAY BE  COPIED ONLY WITH  THE INCLU-

                                     0000    10 ; SION OF  THE  ABOVE  COPYRIGHT NOTICE.  THIS SOFTWARE,  OR  ANY

                                     0000    11 ; OTHER COPIES THEREOF, MAY NOT BE  PROVIDED  OR  OTHERWISE  MADE

                                     0000    12 ; AVAILABLE TO ANY OTHER PERSON EXCEPT  FOR  USE  ON  SUCH SYSTEM

                                     0000    13 ; AND TO  ONE WHO AGREES  TO  THESE LICENSE  TERMS.  TITLE TO AND

                                     0000    14 ; OWNERSHIP OF THE SOFTWARE SHALL AT ALL TIMES REMAIN IN DEC.

                                     0000    15 ;

                                     0000    16 ; THE INFORMATION IN THIS SOFTWARE  IS  SUBJECT TO CHANGE WITHOUT

                                     0000    17 ; NOTICE AND SHOULD NOT BE CONSTRUED  AS  A COMMITMENT BY DIGITAL

                                     0000    18 ; EQUIPMENT CORPORATION.

                                     0000    19 ;

                                     0000    20 ; DEC ASSUMES NO RESPONSIBILITY FOR THE USE OR RELIABILITY OF ITS

                                     0000    21 ; SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DEC.

                                     0000    22 ;

                                     0000    23 ; W. H. BROWN 22-DEC-1977

                                     0000    24 ;

                                     0000    25 ; SYMBOL TABLE MANIPULATION ROUTINES

                                     0000    26 ;

                                     0000    27 ; MACRO LIBRARY CALLS

                                     0000    28 ;

                                     0000    29  

                                     0000    30 	DEFCMDWRK			; DEFINE WORK AREA OFFSETS

                                     0000    31 	DEFERRCOD			; DEFINE ERROR/STATUS VALUES

                                     0000    32 	DEFSYMTBL			; DEFINE SYMBOL ENTRY OFFSETS

                                     0000    33  

                                     0000    34 ;

                                     0000    35 ; LOCAL MACROS

                                     0000    36 ;

                                     0000    37 ; MACRO TO GENERATE AN ENTRY IN THE SPECIAL SYMBOL TABLE

                                     0000    38 ;

                                     0000    39  

                                     0000    40 	.MACRO	SPCSYM	NAME

                                     0000    41 	.SAVE

                                     0000    42 	.PSECT	MCR$ZDATA

                                     0000    43 	.ASCIC	\NAME\

                                     0000    44 	.RESTORE

                                     0000    45 	.WORD	<NAME-SPCDISP>

                                     0000    46 	.ENDM

                                     0000    47  

                                     0000    48 ;

                                     0000    49 ; MACRO TO END THE LIST OF SPECIAL SYMBOLS

                                     0000    50 ;

                                     0000    51  

                                     0000    52 	.MACRO	SPCTRM

                                     0000    53 	.SAVE

                                     0000    54 	.PSECT	MCR$ZDATA

                                     0000    55 	.BYTE	0

                                     0000    56 	.RESTORE

                                     0000    57 	.ENDM

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   2

01                                                                                                                               (1)



                                     0000    58  

                                     0000    59 ;

                                     0000    60 ; LOCAL DATA

                                     0000    61 ;

                                 00000000    62 	.PSECT	MCR$ZCODE,RD,NOWRT,BYTE

                                     0000    63  

                              30 31  0000    64 TRUE:	.ASCII	\10\			; VALUE OF TRUE THEN FALSE

                                 02  0002    65 LOGICAL:.BYTE	SYM_K_LOGICAL		; SYMBOL TABLE ENTRY TYPE OF LOGICAL

                                 04  0003    66 DECNUM:	.BYTE	SYM_K_DECIMAL		; AND FOR DECIMAL NUMBER

                                 00  0004    67 STRING:	.BYTE	SYM_K_STRING		; AND FOR STRING

                                     0005    68  

                                 00000000    69 	.PSECT	MCR$ZDATA,RD,NOWRT,BYTE	; START OF SYMBOL NAME TABLE

                                     0000    70 SPCLTBL:				;

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   3

01              ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE                                                                        (1)



                                     0000    72 	.SBTTL	ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE

                                     0000    73 ;+

                                     0000    74 ; MCR$ALLOCSYM  - ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE

                                     0000    75 ; MCR$ALLOCSYMD - ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE - DISABLE ASTS

                                     0000    76 ;

                                     0000    77 ; THIS ROUTINE IS CALLED TO ALLOCATE AND INSERT A SYMBOL ENTRY IN EITHER THE

                                     0000    78 ; LOCAL OR GLOBAL SYMBOL TABLE.

                                     0000    79 ;

                                     0000    80 ; INPUTS:

                                     0000    81 ;

                                     0000    82 ;	R1 <0:15> = LENGTH OF SYMBOL VALUE.

                                     0000    83 ;	R1 <16:23> = TYPE OF SYMBOL

                                     0000    84 ;	R2 = ADDRESS OF SYMBOL VALUE.

                                     0000    85 ;	R3 = LENGTH OF SYMBOL NAME.

                                     0000    86 ;	R4 = ADDRESS OF SYMBOL NAME.

                                     0000    87 ;	R5 = ADDRESS OF SYMBOL TABLE LISTHEAD.

                                     0000    88 ;

                                     0000    89 ;	IT IS ASSUMED THAT CONTROL Y/C AST'S ARE DISABLED

                                     0000    90 ;	WHEN ENTERED AT MCR$ALLOCSYM.

                                     0000    91 ;

                                     0000    92 ; OUTPUTS:

                                     0000    93 ;

                                     0000    94 ;	THE SPECIFIED SYMBOL TABLE IS SEARCHED FOR THE SPECIFIED ENTRY, AND

                                     0000    95 ;	IF FOUND, THE OLD ENTRY IS DEALLOCATED. A SYMBOL TABLE ENTRY IS THEN

                                     0000    96 ;	ALLOCATED, FILLED WITH THE SYMBOL AND VALUE INFORMATION, AND THEN

                                     0000    97 ;	INSERTED IN THE SPECIFIED SYMBOL TABLE.

                                     0000    98 ;

                                     0000    99 ;	R0 LOW BIT CLEAR INDICATES ALLOCATION FAILURE WITH:

                                     0000   100 ;

                                     0000   101 ;		R0 = MCR$_SYMOVF - NO ROOM FOR SYMBOL DEFINITIONS.

                                     0000   102 ;

                                     0000   103 ;	R0 LOW BIT SET INDICATES SUCCESSFUL COMPLETION.

                                     0000   104 ;

                                     0000   105 ;		R1 = ADDRESS OF ALLOCATED SYMBOL ENTRY.

                                     0000   106 ;-

                                     0000   107  

                                 00000005   108 	.PSECT	MCR$ZCODE,BYTE,RD,NOWRT

                                     0005   109 MCR$ALLOCSYMD::				; ALLOCATE AND INSERT SYAMBOL AFTER DISABLE

                                     0005   110 	DISABLE				; DISABLE CONTROL/Y ASTS

                          8E     7C  0008   111 	CLRQ	(SP)+			; CLEAR RETURN ARGUMENTS

                                     000A   112 MCR$ALLOCSYM::				; ALLOCATE AND INSERT SYMBOL IN TABLE

                          3E     BB  000A   113 	PUSHR	#^M<R1,R2,R3,R4,R5>	; SAVE SYMBOL ENTRY PARAMETERS

            50            55     D0  000C   114 	MOVL	R5,R0			; SET ADDRESS OF SYMBOL TABLE LISTHEAD

            51            53     7D  000F   115 	MOVQ	R3,R1			; SET SYMBOL PARAMETERS

                          00A1   30  0012   116 	BSBW	MCR$SEARCHT		; SEARCH FOR SYMBOL

            08            50     E9  0015   117 	BLBC	R0,10$			; IF LBC NO MATCH FOUND

            01         0A A3     91  0018   118 	CMPB	SYM_B_TYPE(R3),#SYM_K_PERM ; PERMANENT SYMBOL?

                          49     13  001C   119 	BEQL	20$			; IF EQL YES - REFUSE TO REALLOCATE

                          5F     10  001E   120 	BSBB	MCR$DEALLOCSYM		; DEALLOCATE SYMBOL ENTRY

         08 AE            6E     C1  0020   121 10$:	ADDL3	(SP),8(SP),R1		; CALCULATE LENGTH OF SYMBOL STRINGS

                          51         0024       

            51            51     3C  0025   122 	MOVZWL	R1,R1			; CLEAR SYMBOL TYPE FROM THE LENGTH

            51         15 A1     9E  0028   123 	MOVAB	SYM_T_SYMBOL+2+7(R1),R1	; ADD IN FIXED OVERHEAD AND ROUND

                          3C     10  002C   124 	BSBB	MCR$ALLDYNMEM		; ALLOCATE DYNAMIC MEMORY

            0A            50     E8  002E   125 	BLBS	R0,16$			; BR IF ALLOCATION WORKED OK

            53         34 BB     0F  0031   126 	REMQUE	@PRC_Q_LABEL+4(R11),R3	; REMOVE A LABEL TABLE ENTRY

                          30     1D  0035   127 	BVS	20$			; IF V=1, NO ENTRIES IN LABEL TABLE

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   4

01              ALLOCATE AND INSERT ENTRY IN SYMBOL TABLE                                                                        (1)



                          46     10  0037   128 	BSBB	MCR$DEALLOCSYM		; DEALLOCATE THE LABEL ENTRY

                          E5     11  0039   129 	BRB	10$			; TRY AGAIN TO ALLOCATE THE SYMBOL

         08 A2            51     D0  003B   130 16$:	MOVL	R1,SYM_W_SIZE(R2)	; SET SIZE OF ALLOCATED BLOCK

                          52     DD  003F   131 	PUSHL	R2			; SAVE ADDRESS OF ALLOCATED BLOCK

                          3F     BA  0041   132 	POPR	#^M<R0,R1,R2,R3,R4,R5>	; RETRIEVE SYMBOL PARAMETERS

                          50     DD  0043   133 	PUSHL	R0			; SAVE ADDRESS OF ALLOCATED BLOCK

            65            60     0E  0045   134 	INSQUE	SYM_L_FL(R0),(R5)	; INSERT ENTRY IN SYMBOL TABLE

            08            10     EF  0048   135 	EXTZV	#16,#8,R1,SYM_B_TYPE(R0); INSERT TYPE OF SYMBOL INTO ENTRY

         0A A0            51         004B       

                          06     BB  004E   136 	PUSHR	#^M<R1,R2>		; SAVE VALUE PARAMETERS

         0C A0            53     90  0050   137 	MOVB	R3,SYM_T_SYMBOL(R0)	; INSERT LENGTH OF SYMBOL

            64            53     28  0054   138 	MOVC	R3,(R4),SYM_T_SYMBOL+1(R0) ; INSERT SYMBOL NAME

                       0D A0         0057       

                          06     BA  0059   139 	POPR	#^M<R1,R2>		; RETRIEVE VALUE PARAMETERS

            83            51     90  005B   140 	MOVB	R1,(R3)+		; INSERT LENGTH OF VALUE

            62            51     28  005E   141 	MOVC	R1,(R2),(R3)		; INSERT VALUE

                          63         0061       

                          02     BA  0062   142 	POPR	#^M<R1>			; RETRIEVE ADDRESS OF SYMBOL ENTRY

                          50     D6  0064   143 	INCL	R0			; SET SUCCESS INDICATOR

                                 05  0066   144 	RSB				; 

                          3E     BA  0067   145 20$:	POPR	#^M<R1,R2,R3,R4,R5>	; RESTORE SYMBOL PARAMETERS

                                 05  0069   146 	RSB				; 

                                     006A   147 ;+

                                     006A   148 ; MCR$ALLDYNMEM - DISPATCH TO MEMORY ALLOCATION SUBROUTINE

                                     006A   149 ;

                                     006A   150 ; ENTER HERE TO DISPATCH TO THE MEMORY ALLOCATION ROUTINE

                                     006A   151 ;

                                     006A   152 ; INPUT:

                                     006A   153 ;

                                     006A   154 ;	R1 = SIZE OF BLOCK PLUS ROUND UP FACTOR OF 7

                                     006A   155 ;

                                     006A   156 ; OUTPUTS:

                                     006A   157 ;

                                     006A   158 ;	R1 = SIZE OF BLOCK ALLOCATED

                                     006A   159 ;	R2 = ADDRESS OF BLOCK

                                     006A   160 ;	R3 IS DESTROYED

                                     006A   161 ;-

                                     006A   162 MCR$ALLDYNMEM::				;  ALLOCATE DYNAMIC MEMORY

            53         20 AB     9E  006A   163 	MOVAB	PRC_Q_ALLOCREG(R11),R3	; GET ADDRESS OF ALLOCATION LISTHEAD

            51            07     CA  006E   164 	BICL	#7,R1			; TRUNCATE TO QUADWORD MULTIPLE

                 00000000'9F     16  0071   165 	JSB	@#EXE$ALLOCATE		; ALLOCATE SYMBOL TABLE ENTRY

            04            50     E8  0077   166 	BLBS	R0,20$			; BR IF NO ERROR

                                     007A   167 	STATUS	SYMOVF			; SET ERROR

                                 05  007E   168 20$:	RSB				;

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   5

01              DEALLOCATE SYMBOL TABLE ENTRY                                                                                    (1)



                                     007F   170 	.SBTTL	DEALLOCATE SYMBOL TABLE ENTRY

                                     007F   171 ;+

                                     007F   172 ; MCR$DEALLOCSYM - DEALLOCATE SYMBOL TABLE ENTRY

                                     007F   173 ; MCR$DEADYNMEM  - DEALLOCATE DYNAMIC MEMORY

                                     007F   174 ;

                                     007F   175 ; THIS ROUTINE IS CALLED TO REMOVE A SYMBOL FROM ITS TABLE AND/OR

                                     007F   176 ; DEALLOCATE DYNAMIC MEMORY USED.

                                     007F   177 ;

                                     007F   178 ; INPUTS TO DEALLOCSYM:

                                     007F   179 ;

                                     007F   180 ;	R3 = ADDRESS OF SYMBOL ENTRY.

                                     007F   181 ;

                                     007F   182 ; INPUTS TO DEALDYNMEM:

                                     007F   183 ;

                                     007F   184 ;	R0 = ADDRESS OF BLOCK TO DEALLOCATE

                                     007F   185 ;	R1 = SIZE OF BLOCK

                                     007F   186 ;

                                     007F   187 ;	IT IS ASSUMED THAT CONTROL Y/C AST'S ARE DISABLED.

                                     007F   188 ;

                                     007F   189 ; OUTPUTS:

                                     007F   190 ;

                                     007F   191 ;	THE SYMBOL IS REMOVED FROM ITS TABLE AND/OR ITS STORAGE IS DEALLOCATED.

                                     007F   192 ;-

                                     007F   193  

                                     007F   194 MCR$DEALLOCSYM::			; DEALLOCATE SYMBOL TABLE ENTRY

            50            63     0F  007F   195 	REMQUE	SYM_L_FL(R3),R0		; REMOVE SYMBOL ENTRY FROM ITS TABLE

            51         08 A0     3C  0082   196 	MOVZWL	SYM_W_SIZE(R0),R1	; GET SIZE OF BLOCK TO DEALLOCATE

                                     0086   197 MCR$DEADYNMEM::				; DEALLOCATE DYNAMIC MEMORY

            53         20 AB     9E  0086   198 	MOVAB	PRC_Q_ALLOCREG(R11),R3	; GET ADDRESS OF ALLOCATION LISTHEAD

                 00000000'9F     17  008A   199 	JMP	@#EXE$DEALLOCATE	; DEALLOCATE SYMBOL ENTRY STORAGE

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   6

01              SEARCH FOR SYMBOL ENTRY                                                                                          (1)



                                     0090   201 	.SBTTL	SEARCH FOR SYMBOL ENTRY

                                     0090   202 ;+

                                     0090   203 ; MCR$SEARCH - SEARCH FOR SYMBOL ENTRY

                                     0090   204 ;

                                     0090   205 ; THIS ROUTINE IS CALLED TO SEARCH THE LOCAL AND GLOBAL SYMBOL TABLES FOR

                                     0090   206 ; AN ENTRY.

                                     0090   207 ;

                                     0090   208 ; INPUTS:

                                     0090   209 ;

                                     0090   210 ;	R1 = LENGTH OF SYMBOL.

                                     0090   211 ;	R2 = ADDRESS OF SYMBOL.

                                     0090   212 ;

                                     0090   213 ; OUTPUTS:

                                     0090   214 ;

                                     0090   215 ;	THE LOCAL FOLLOWED BY THE GLOBAL SYMBOL TABLE IS SEARCH FOR A SYMBOL

                                     0090   216 ;	MATCH.

                                     0090   217 ;

                                     0090   218 ;	R0 LOW BIT CLEAR INDICATES A SEARCH FAILURE WITH:

                                     0090   219 ;

                                     0090   220 ;		R1 = ZERO.

                                     0090   221 ;

                                     0090   222 ;	R0 LOW BIT SET INDICATES A SYMBOL MATCH WITH:

                                     0090   223 ;

                                     0090   224 ;		R1 = LENGTH OF SYMBOL VALUE.

                                     0090   225 ;		R2 = ADDRESS OF SYMBOL VALUE.

                                     0090   226 ;		R3 = ADDRESS OF SYMBOL ENTRY.

                                     0090   227 ;-

                                     0090   228  

                                     0090   229 MCR$SEARCH::				; SEARCH FOR SYMBOL ENTRY

            3C            62     91  0090   230 	CMPB	(R2),#^A/</		; IS THIS A SPECIAL SYMBOL

                          47     13  0093   231 	BEQL	MCR$SPCLSYMB		; BR IF YES

            50         38 AB     9E  0095   232 	MOVAB	PRC_Q_LOCAL(R11),R0	; SET ADDRESS OF LOCAL SYMBOL TABLE LISTHEAD

                          1B     10  0099   233 	BSBB	MCR$SEARCHT		; SEARCH LOCAL SYMBOL TABLE FOR ENTRY

            0B            50     E8  009B   234 	BLBS	R0,10$			; IF LBS MATCH FOUND

            50         28 AB     9E  009E   235 	MOVAB	PRC_Q_GLOBAL(R11),R0	; SET ADDRESS OF GLOBAL SYMBOL TABLE LISTHEAD

                          12     10  00A2   236 	BSBB	MCR$SEARCHT		; SEARCH GLOBAL SYMBOL TABLE FOR ENTRY

                          51     D4  00A4   237 	CLRL	R1			; ASSUME NO MATCH FOUND

            0C            50     E9  00A6   238 	BLBC	R0,20$			; IF LBC NO MATCH FOUND

            52         0C A3     9A  00A9   239 10$:	MOVZBL	SYM_T_SYMBOL(R3),R2	; GET LENGTH OF SYMBOL

            52         0D A342   9E  00AD   240 	MOVAB	SYM_T_SYMBOL+1(R3)[R2],R2 ; GET ADDRESS OF VALUE LENGTH

            51            82     9A  00B2   241 	MOVZBL	(R2)+,R1		; GET LENGTH OF VALUE

                                 05  00B5   242 20$:	RSB				; 

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   7

01              SEARCH SPECIFIC SYMBOL TABLE FOR ENTRY                                                                           (1)



                                     00B6   244 	.SBTTL	SEARCH SPECIFIC SYMBOL TABLE FOR ENTRY

                                     00B6   245 ;+

                                     00B6   246 ; MCR$SEARCHT - SEARCH SPECIFIC SYMBOL TABLE FOR ENTRY

                                     00B6   247 ;

                                     00B6   248 ; THIS ROUTINE IS CALLED TO SEARCH A SPECIFIC SYMBOL TABLE FOR AN ENTRY.

                                     00B6   249 ;

                                     00B6   250 ; INPUTS:

                                     00B6   251 ;

                                     00B6   252 ;	R0 = ADDRESS OF SYMBOL TABLE LISTHEAD.

                                     00B6   253 ;	R1 = LENGTH OF SYMBOL NAME.

                                     00B6   254 ;	R2 = ADDRESS OF SYMBOL NAME.

                                     00B6   255 ;

                                     00B6   256 ; OUTPUTS:

                                     00B6   257 ;

                                     00B6   258 ;	R0 LOW BIT CLEAR INDICATES SEARCH FAILURE.

                                     00B6   259 ;

                                     00B6   260 ;		R1 = LENGTH OF SYMBOL NAME.

                                     00B6   261 ;		R2 = ADDRESS OF SYMBOL NAME.

                                     00B6   262 ;

                                     00B6   263 ;	R0 LOW BIT SET INDICATES SYMBOL FOUND WITH:

                                     00B6   264 ;

                                     00B6   265 ;		R1 = LENGTH OF SYMBOL NAME.

                                     00B6   266 ;		R2 = ADDRESS OF SYMBOL NAME.

                                     00B6   267 ;		R3 = ADDRESS OF SYMBOL ENTRY.

                                     00B6   268 ;-

                                     00B6   269  

                                     00B6   270 MCR$SEARCHT::				; SEARCH SPECIFIC SYMBOL TABLE FOR ENTRY

            53            50     D0  00B6   271 	MOVL	R0,R3			; COPY ADDRESS OF SYMBOL TABLE LISTHEAD

            53            63     D0  00B9   272 10$:	MOVL	SYM_L_FL(R3),R3		; GET ADDRESS OF NEXT ENTRY

            53            50     D1  00BC   273 	CMPL	R0,R3			; END OF TABLE?

                          16     13  00BF   274 	BEQL	20$			; IF EQL YES

            54         0C A3     9E  00C1   275 	MOVAB	SYM_T_SYMBOL(R3),R4	; GET ADDRESS OF SYMBOL LENGTH

            84            51     91  00C5   276 	CMPB	R1,(R4)+		; SYMBOL LENGTH MATCH?

                          EF     12  00C8   277 	BNEQ	10$			; IF NEQ NO

                          1F     BB  00CA   278 	PUSHR	#^M<R0,R1,R2,R3,R4>	; SAVE SEARCH PARAMETERS

            62            51     29  00CC   279 	CMPC	R1,(R2),(R4)		; SYMBOLS MATCH?

                          64         00CF       

                          1F     BA  00D0   280 	POPR	#^M<R0,R1,R2,R3,R4>	; RESTORE SEARCH PARAMETERS

                          E5     12  00D2   281 	BNEQ	10$			; IF NEQ NO

                          50     D6  00D4   282 	INCL	R0			; SET SUCCESS INDICATOR

                                 05  00D6   283 	RSB				; 

                                     00D7   284 20$:	STATUS	UNDSYM			; SET SYMBOL UNDEFINED

                                 05  00DB   285 	RSB				;

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   8

01              SEARCH FOR SPECIAL SYMBOL                                                                                        (1)



                                     00DC   287 	.SBTTL	SEARCH FOR SPECIAL SYMBOL

                                     00DC   288 ;+

                                     00DC   289 ; MCR$SPCLSYMB - SEARCH FOR SPECIAL SYMBOL

                                     00DC   290 ;

                                     00DC   291 ; THIS ROUTINE IS CALLED TO SEARCH THE SPECIAL SYMBOL TABLE FOR AN ENTRY.

                                     00DC   292 ;

                                     00DC   293 ; INPUTS:

                                     00DC   294 ;

                                     00DC   295 ;	R1 = LENGTH OF SYMBOL NAME.

                                     00DC   296 ;	R2 = ADDRESS OF SYMBOL NAME.

                                     00DC   297 ;

                                     00DC   298 ; OUTPUTS:

                                     00DC   299 ;

                                     00DC   300 ;	R0 LOW BIT CLEAR INDICATES SEARCH FAILURE.

                                     00DC   301 ;

                                     00DC   302 ;	R0 LOW BIT SET INDICATES SYMBOL FOUND WITH:

                                     00DC   303 ;

                                     00DC   304 ;		R1 = LENGTH OF SYMBOL VALUE.

                                     00DC   305 ;		R2 = ADDRESS OF SYMBOL VALUE.

                                     00DC   306 ;		R3 = ADDRESS OF DUMMY SYMBOL ENTRY.

                                     00DC   307 ;-

                                     00DC   308 MCR$SPCLSYMB::				; SEARCH SPECIAL SYMBOL

                          52     D6  00DC   309 	INCL	R2			; ADJUST PAST "<"

            51            02     C2  00DE   310 	SUBL	#2,R1			; ADJUST COUNT FOR "<>"

            55       0000'CF     9E  00E1   311 	MOVAB	W^SPCLTBL,R5		; SET ADDRESS OF TABLE

                          FF17'  30  00E6   312 	BSBW	MCR$SRCTBL		; SEARCH FOR THE ENTRY

            01            54     AF  00E9   313 	CASEW	R4,#1,S^#<<<SPCEND-SPCDISP>/2>-1> ; DECODE SYMBOL NAME

                          0B'        00EC       

                                     00ED   314 SPCDISP:SPCSYM	MAPPED			; IS SYSTEM MAPPED

                                     00EF   315 	SPCSYM	ALTMOD			; ALTMODE TERMINATOR

                                     00F1   316 	SPCSYM	ESCAPE			; ESCAPE TERMINATOR, SYNONYM FOR ALTMODE

                                     00F3   317 	SPCSYM	DEFAUL			; LAST RESPONCE DEFAULTED

                                     00F5   318 	SPCSYM	RAD50			; LAST ANSWER ONLY RAD50 CHARS

                                     00F7   319 	SPCSYM	ALPHAN			; LAST ANSWER ONLY ALPHA/NUMERIC

                                     00F9   320 	SPCSYM	MEMSIZ			; SIZE OF MEMORY

                                     00FB   321 	SPCSYM	SYUNIT			; UNIT FOR SYSTEM DEVICE

                                     00FD   322 	SPCSYM	STRLEN			; LENGTH OF LAST STRING TESTED

                                     00FF   323 	SPCSYM	SYDISK			; NAME OF SYSTEM DISK

                                     0101   324 	SPCSYM	UIC			; CURRENT UIC (DIRECTORY)

                                     0103   325 	SPCSYM	SYSUIC			; SYSTEM UIC

                                     0105   326 SPCEND:	SPCTRM				; TERMINATE THE TABLE

                                     0105   327 	STATUS	INVKEY			; INDICATE UNRECOGNIZED KEY

                                 05  0109   328 	RSB				; RETURN WITH STATUS

                                     010A   329  

                                     010A   330 ;

                                     010A   331 ; PROCESS INQUIRY ABOUT LOGIACL FLAGS

                          0D     10  010A   332 MAPPED:BSBB	TRUFLS			; IS SYSTEM MAPPED?

                                 FF  010C   333 	.BYTE	-1			; ALWAYS TRUE

                                     010D   334  

                                     010D   335 ALTMOD:					; LAST ASK AND WITH ALTMODE?

                          0A     10  010D   336 ESCAPE:	BSBB	TRUFLS			; SAME AS ESCAPE

                                 02  010F   337 	.BYTE	MCR_V_ESCAPE		; BIT TO TEST TO FIND OUT

                                     0110   338  

                          07     10  0110   339 DEFAUL:	BSBB	TRUFLS			; LAST ANSWER DEFAULTED?

                                 03  0112   340 	.BYTE	MCR_V_DEFALT		; BIT TO TEST TO TELL

                                     0113   341  

                          04     10  0113   342 RAD50:	BSBB	TRUFLS			; LAST STRING TEST RAD50 CHARS

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page   9

01              SEARCH FOR SPECIAL SYMBOL                                                                                        (1)



                                 00  0115   343 	.BYTE	MCR_V_RAD50		; BIT TO TEST TO TELL

                                     0116   344  

                          01     10  0116   345 ALPHAN:	BSBB	TRUFLS			; LAST STRING TEST ALPHA/NUMERIC CHARS

                                 01  0118   346 	.BYTE	MCR_V_ALPHAN		; BIT TO TEST TO TELL

                                     0119   347  

            53       FEDB CF     9E  0119   348 TRUFLS:	MOVAB	LOGICAL-SYM_B_TYPE,R3	; SET DUMMY SYMBOL TABLE ENTRY

            52       FEDE CF     9E  011E   349 	MOVAB	TRUE,R2			; ASSUME ANSWER IS TRUE

            51            01     D0  0123   350 	MOVL	#1,R1			; ALWAYS 1 BYTE LONG

            50            9E     98  0126   351 	CVTBL	@(SP)+,R0		; GET THE BIT TO TEST

                          07     19  0129   352 	BLSS	10$			; BR IF ALWAYS TRUE

         52 AB            50     E0  012B   353 	BBS	R0,PRC_W_CLIFLAG(R11),10$ ; BR IF FLAG IS SET TRUE

                          02         012F       

                          52     D6  0130   354 	INCL	R2			; CHANGE VALUE TO FALSE

                                     0132   355 10$:	STATUS	NORMAL			;

                                 05  0135   356 	RSB				;

                                     0136   357  

                                     0136   358 ;

                                     0136   359 ; PROCESS INQUIRY ABOUT NUMERIC SYMBOLS

                                     0136   360 ;

                                     0136   361 	.ENABL	LSB

                                     0136   362  

                          08     10  0136   363 MEMSIZ:	BSBB	10$			; RETURN NUMBER

                        2E 32 33 00' 0138   364 	.ASCIC	/32./			; SIZE OF MEMORY

                                 03  0138       

                                     013C   365  

                          02     10  013C   366 SYUNIT:	BSBB	10$			; THE UNIT NUMBER FOR SYSTEM DISK

                              30 00' 013E   367 	.ASCIC	/0/			; ALWAYS ZERO

                                 01  013E       

                                     0140   368  

            53       FEB5 CF     9E  0140   369 10$:	MOVAB	DECNUM-SYM_B_TYPE,R3	; SET DUMMY SYMBOL TABLE ENTRY

                          1B     11  0145   370 	BRB	30$			;

                                     0147   371  

                          14     10  0147   372 SYDISK:	BSBB	20$			; SET NAME OF SYSTEM DISK

                           59 53 00' 0149   373 	.ASCIC	/SY/			; NAME IS ALWAYS "SY"

                                 02  0149       

                                     014C   374  

                 00000000'9F     9F  014C   375 UIC:	PUSHAB	@#PIO$GT_DDSTRING	; ADDRESS OF THE STRING

                          09     11  0152   376 	BRB	20$			;

                                     0154   377  

                          07     10  0154   378 SYSUIC:	BSBB	20$			; RETURN SYSTEM UIC

               5D 34 35 2C 31 5B 00' 0156   379 	.ASCIC	/[1,54]/		; ALWAYS [1,54]

                                 06  0156       

                                     015D   380  

            53       FE99 CF     9E  015D   381 20$:	MOVAB	STRING-SYM_B_TYPE,R3	; SET DUMMY SYMBOL TABLE ENTRY

                          04     BA  0162   382 30$:	POPR	#^M<R2>			; ADDRESS OF COUNTED STRING

            51            82     9A  0164   383 	MOVZBL	(R2)+,R1		; CONVERT TO STRING DESCRIPTOR

                          11     11  0167   384 	BRB	50$			; GET OUT

                                     0169   385  

                                     0169   386  

                                     0169   387 ;

                                     0169   388 ; REQUEST FOR STRING LENGTH FROM LAST TEST OR ASKS

                                     0169   389 ;

                                     0169   390  

            52         5C AB     9E  0169   391 STRLEN:	MOVAB	PRC_L_CLIWRK0(R11),R2	; SET ADDRESS OF STRING

                          51     D4  016D   392 	CLRL	R1			; START WITH INDEX OF ZERO

            2E            8142   91  016F   393 40$:	CMPB	(R1)+[R2],#^A/./	; END OF STRING?

                          FA     12  0173   394 	BNEQ	40$			; BR IF NO

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page  10

01              SEARCH FOR SPECIAL SYMBOL                                                                                        (1)



            53       FE80 CF     9E  0175   395 	MOVAB	DECNUM-SYM_B_TYPE,R3	; SET DUMMY SYMBOL TABLE ENTRY

                                     017A   396 50$:	STATUS	NORMAL			; SET GOOD STATUS

                                 05  017D   397 	RSB				; RETURN

                                     017E   398  

                                     017E   399 	.END

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page  11

SYMBOL TABLE                                                                                                                     (1)



ALPHAN           00000116 R     03   CLI$_ONLEVL    = 00038100            MCR_V_ESCAPE   = 00000002            

ALTMOD           0000010D R     03   CLI$_ONOVF     = 00038108            MCR_V_ESCTRM   = 00000009            

BIT...         = 00000006            CLI$_OVRFLW    = 00038160            MCR_V_FORCMD   = 0000000E            

CLI$_ABFNAM    = 000381B8            CLI$_PARMDEL   = 00038110            MCR_V_GLOBAL   = 0000000A            

CLI$_ABKEYW    = 00038000            CLI$_PROC_ID   = 0003FFF1            MCR_V_LOWER    = 0000000B            

CLI$_ABVERB    = 00038008            CLI$_QUEJOBCRE = 0003FFF9            MCR_V_OPNINP   = 00000006            

CLI$_BADRET    = 00038198            CLI$_REQPRMABS = 00038812            MCR_V_RAD50    = 00000000            

CLI$_BADTEXT   = 000381B0            CLI$_RSLOVF    = 00038118            MCR_V_STRSUB   = 0000000C            

CLI$_BUFOVF    = 00038018            CLI$_SKPDAT    = 00038120            MEMSIZ           00000136 R     03   

CLI$_COMPLX    = 00038020            CLI$_SPARE0    = 00038010            MSGBUFSIZ      = 00000084            

CLI$_CONFQUAL  = 00038802            CLI$_SPARE1    = 00038058            PIO$GT_DDSTRING  ********   X   03   

CLI$_CREQUEJOB = 0003884A            CLI$_STKOVF    = 00038128            PRC_B_DEFRADIX   00000092            

CLI$_DEFOVF    = 00038028            CLI$_SUBMITERR = 00038852            PRC_B_EXMDEPMOD  00000091            

CLI$_DEVALSPL  = 0003885A            CLI$_SYMDEL    = 00038130            PRC_B_EXMDEPWID  00000090            

CLI$_DEVNOTFOR = 0003887A            CLI$_SYMOVF    = 00038138            PRC_K_DEC      = 00000001            

CLI$_DEVNOTSPL = 00038862            CLI$_UNDFIL    = 00038188            PRC_K_HEX      = 00000000            

CLI$_DIRECT    = 00038030            CLI$_UNDSYM    = 00038140            PRC_K_LENGTH     000000A0            

CLI$_EXPSYN    = 00038038            CLI$_UNPROPARM = 00038170            PRC_K_OCT      = 00000002            

CLI$_FILOPN    = 00038190            CLI$_UNPROQUAL = 00038168            PRC_L_CLIWRK0    0000005C            

CLI$_ILLVAL    = 0003883A            CLI$_USGOTO    = 00038148            PRC_L_CLIWRK1    00000060            

CLI$_IMCHNG    = 00038040            CLI$_VALCNVERR = 00038832            PRC_L_CLIWRK2    00000064            

CLI$_IMGFNF    = 00038872            CLI$_VALREQ    = 00038150            PRC_L_CLIWRK3    00000068            

CLI$_INSFPRM   = 00038048            CMDBUFSIZ      = 000001FC            PRC_L_CLIWRK4    0000006C            

CLI$_INVKEY    = 00038178            DECNUM           00000003 R     03   PRC_L_ERRRAB     00000010            

CLI$_INVQUAL   = 0003880A            DEFAUL           00000110 R     03   PRC_L_EXMDEPADR  0000008C            

CLI$_INVQUALNUM= 0003881A            ESCAPE           0000010D R     03   PRC_L_EXTARG     00000078            

CLI$_INVREQTYP = 00038822            EXE$ALLOCATE     ********   X   03   PRC_L_EXTBLK     00000070            

CLI$_INVRSP    = 00038180            EXE$DEALLOCATE   ********   X   03   PRC_L_EXTCOD     00000080            

CLI$_INVUIC    = 000381A8            GBL...         = 00000000            PRC_L_EXTHND     00000074            

CLI$_IVCHAR    = 00038050            INPBUFSIZ      = 00000084            PRC_L_EXTPRM     0000007C            

CLI$_IVDEVTYPE = 0003886A            LOGICAL          00000002 R     03   PRC_L_INDEPTH    00000048            

CLI$_IVFNAM    = 000381C0            MAPPED           0000010A R     03   PRC_L_INDFAB     0000001C            

CLI$_IVKEYW    = 00038060            MCR$ALLDYNMEM    0000006A RG    03   PRC_L_INDINPRAB  00000014            

CLI$_IVOPER    = 00038068            MCR$ALLOCSYM     0000000A RG    03   PRC_L_INDOUTRAB  00000018            

CLI$_IVPROT    = 00038070            MCR$ALLOCSYMD    00000005 RG    03   PRC_L_INPRAB     00000008            

CLI$_IVQLOC    = 00038078            MCR$DEADYNMEM    00000086 RG    03   PRC_L_LSTSTATUS  00000094            

CLI$_IVSYMB    = 00038080            MCR$DEALLOCSYM   0000007F RG    03   PRC_L_ONCTLY     0000009C            

CLI$_IVVALU    = 00038088            MCR$DISABLE      ********   X   03   PRC_L_ONERROR    00000058            

CLI$_IVVERB    = 00038090            MCR$SEARCH       00000090 RG    03   PRC_L_OUTRAB     0000000C            

CLI$_MAXPARM   = 00038098            MCR$SEARCHT      000000B6 RG    03   PRC_L_PROCUIC    00000098            

CLI$_MULKEY    = 000381A0            MCR$SPCLSYMB     000000DC RG    03   PRC_L_SAVAP      00000000            

CLI$_NOATFIL   = 000380A0            MCR$SRCTBL       ********   X   03   PRC_L_SAVFP      00000004            

CLI$_NOCCAT    = 000380A8            MCR_M_ALPHAN   = 00000002            PRC_L_SEVERITY   00000040            

CLI$_NOCOMD    = 000380B0            MCR_M_DEFALT   = 00000008            PRC_L_STACKLM    00000088            

CLI$_NOKEYW    = 000380B8            MCR_M_DELINP   = 00000080            PRC_L_STACKPT    00000084            

CLI$_NOLIST    = 000380C0            MCR_M_DOLLARS  = 00000100            PRC_L_STATUS     00000044            

CLI$_NOOPTPRS  = 00038842            MCR_M_ESCAPE   = 00000004            PRC_L_SYMBOL     0000004C            

CLI$_NOQUAL    = 000380C8            MCR_M_ESCTRM   = 00000200            PRC_M_CNTRLY   = 00000002            

CLI$_NORMAL    = 00030001            MCR_M_GLOBAL   = 00000400            PRC_M_DBGQUAL  = 00000200            

CLI$_NOTNEG    = 000380D8            MCR_M_LOWER    = 00000800            PRC_M_DBGTRUE  = 00000400            

CLI$_NOVALU    = 000380D0            MCR_M_OPNINP   = 00000040            PRC_M_DISABL   = 00000004            

CLI$_NOVALUE   = 0003882A            MCR_M_RAD50    = 00000001            PRC_M_EXIT     = 00000008            

CLI$_NULFIL    = 000380E0            MCR_M_STRSUB   = 00001000            PRC_M_GOEOF    = 00000001            

CLI$_NUMBER    = 000380E8            MCR_V_ALPHAN   = 00000001            PRC_M_GOTO     = 00000010            

CLI$_ONCOMD    = 000380F0            MCR_V_DEFALT   = 00000003            PRC_M_HANGUP   = 00001000            

CLI$_ONERR     = 000380F8            MCR_V_DELINP   = 00000007            PRC_M_IND      = 00000020            

CLI$_ONEVAL    = 00038158            MCR_V_DOLLARS  = 00000008            PRC_M_MODE     = 00000040            

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page  12

SYMBOL TABLE                                                                                                                     (1)



PRC_M_NOCTLY   = 00004000            WRK_B_PARMCNT    FFFFFFCB            

PRC_M_PAUSE    = 00002000            WRK_B_VERBTYP    FFFFFFC8            

PRC_M_USRDET   = 00000100            WRK_K_LENGTH     FFFFFBC0            

PRC_M_VERIFY   = 00000080            WRK_L_CHARPTR    FFFFFFFC            

PRC_M_YLEVEL   = 00000800            WRK_L_IMAGE      FFFFFFEC            

PRC_Q_ALLOCREG   00000020            WRK_L_MAXPARM    FFFFFFCC            

PRC_Q_GLOBAL     00000028            WRK_L_MINPARM    FFFFFFD0            

PRC_Q_LABEL      00000030            WRK_L_PAROUT     FFFFFFF0            

PRC_Q_LOCAL      00000038            WRK_L_PROMPT     FFFFFFF4            

PRC_V_CNTRLY   = 00000001            WRK_L_QUABLK     FFFFFFE8            

PRC_V_DBGQUAL  = 00000009            WRK_L_RSLNXT     FFFFFD40            

PRC_V_DBGTRUE  = 0000000A            WRK_L_SAVAP      FFFFFFD8            

PRC_V_DISABL   = 00000002            WRK_L_SAVFP      FFFFFFDC            

PRC_V_EXIT     = 00000003            WRK_L_SAVSP      FFFFFFD4            

PRC_V_GOEOF    = 00000000            WRK_M_ALL      = 00000001            

PRC_V_GOTO     = 00000004            WRK_M_ASK      = 00000100            

PRC_V_HANGUP   = 0000000C            WRK_M_COMMAND  = 00000002            

PRC_V_IND      = 00000005            WRK_M_CONTINU  = 00000400            

PRC_V_MODE     = 00000006            WRK_M_EQUAL    = 00000008            

PRC_V_NOCTLY   = 0000000E            WRK_M_IMCHNG   = 00000004            

PRC_V_PAUSE    = 0000000D            WRK_M_QUAL     = 00000010            

PRC_V_USRDET   = 00000008            WRK_M_QUOTE    = 00000020            

PRC_V_VERIFY   = 00000007            WRK_M_STAR     = 00000040            

PRC_V_YLEVEL   = 0000000B            WRK_M_TRAILSPC = 00000200            

PRC_W_CLIFLAG    00000052            WRK_M_VERB     = 00000080            

PRC_W_ERRIFI     00000052            WRK_Q_IOSB       FFFFFFE0            

PRC_W_FLAGS      00000054            WRK_V_ALL      = 00000000            

PRC_W_INPCHAN    00000050            WRK_V_ASK      = 00000008            

PRC_W_ONLEVEL    00000056            WRK_V_COMMAND  = 00000001            

RAD50            00000113 R     03   WRK_V_CONTINU  = 0000000A            

RSLBUFSIZ      = 00000180            WRK_V_EQUAL    = 00000003            

SPCDISP          000000ED R     03   WRK_V_IMCHNG   = 00000002            

SPCEND           00000105 R     03   WRK_V_QUAL     = 00000004            

SPCLTBL          00000000 R     04   WRK_V_QUOTE    = 00000005            

STRING           00000004 R     03   WRK_V_STAR     = 00000006            

STRLEN           00000169 R     03   WRK_V_TRAILSPC = 00000009            

SYDISK           00000147 R     03   WRK_V_VERB     = 00000007            

SYM_B_TYPE       0000000A            WRK_W_FLAGS      FFFFFFFA            

SYM_K_DECIMAL  = 00000004            WRK_W_LOCFLG     FFFFFFF8            

SYM_K_HEXDEC   = 00000005            _$$_           = 0000005E            

SYM_K_LOGICAL  = 00000002            

SYM_K_OCTAL    = 00000003            

SYM_K_PERM     = 00000001            

SYM_K_STRING   = 00000000            

SYM_L_BL         00000004            

SYM_L_FL         00000000            

SYM_T_SYMBOL     0000000C            

SYM_W_SIZE       00000008            

SYSUIC           00000154 R     03   

SYUNIT           0000013C R     03   

TRUE             00000000 R     03   

TRUFLS           00000119 R     03   

UIC              0000014C R     03   

WRK_AB_BUFFER    FFFFFD44            

WRK_AG_RESULT    FFFFFBC0            

WRK_B_CMDFLG     FFFFFFC9            

WRK_B_CURADX     FFFFFFCA            

MCRSYMBOL       - SYMBOL TABLE MANIPULATION ROUTINES             22-AUG-1978 01:54:46   VAX-11 MACRO X0.3-11               Page  13

PROGRAM SECTION SYNOPSIS                                                                                                         (1)







PROGRAM SECTION SYNOPSIS



.  ABS  .        00000000      00     NOPIC   USR   CON   ABS   LCL NOSHR NOEXE NORD  NOWRT BYTE  

. BLANK .        00000000      01     NOPIC   USR   CON   REL   LCL NOSHR   EXE   RD    WRT BYTE  

$ABS$            FFFFFFFC      02     NOPIC   USR   CON   ABS   LCL NOSHR   EXE   RD    WRT BYTE  

MCR$ZCODE        0000017E      03     NOPIC   USR   CON   REL   LCL NOSHR   EXE   RD  NOWRT BYTE  

MCR$ZDATA        00000051      04     NOPIC   USR   CON   REL   LCL NOSHR   EXE   RD  NOWRT BYTE  





THERE WERE NO ERRORS OR WARNINGS.

17750. BYTES LEFT IN FREE MEMORY POOL.

926. BYTES OF RECLAIMED MEMORY.

OBJ$:MCRSYMBOL,LIS$:MCRSYMBOL/-SP=EXECML$/ML,LIB$:MCR/ML,SRC$:MCRSYMBOL

21 MLB DIR RDS - 391 GETS TO DEFINE 17 MACROS. 32 INTER. FILE WRITES. 

